[go: up one dir, main page]

Menu

#109 error: cannot initialize a variable of type 'char *' with an rvalue of type 'void *'

open
brummer
None
v1.0_(example)
1
2020-06-10
2020-06-10
Yuri
No
[1050/1114] Compiling src/LV2/xputty/xpngloader.cpp
18:00:15 runner ['c++', '-O2', '-pipe', '-fno-omit-frame-pointer', '-fstack-protector-strong', '-isystem', '/usr/local/include', '-fno-strict-aliasing', '-fno-omit-frame-pointer', '-isystem', '/usr/local/include', '-Wall', '-DGSEAL_ENABLE', '-O3', '-DNDEBUG', '-D_FILE_OFFSET_BITS=64', '-std=c++11', '-fPIC', '-pthread', '-Isrc/LV2/xputty', '-I../src/LV2/xputty', '-Isrc/LV2/xputty/header', '-I../src/LV2/xputty/header', '-Isrc/LV2/xputty/header/widgets', '-I../src/LV2/xputty/header/widgets', '-Isrc/LV2/xputty/header/dialogs', '-I../src/LV2/xputty/header/dialogs', '-Isrc/LV2/xputty/resources', '-I../src/LV2/xputty/resources', '-Isrc/LV2/xputty/xdgmime', '-I../src/LV2/xputty/xdgmime', '-I../../../../../../local/include/cairo', '-I../../../../../../local/include/glib-2.0', '-I../../../../../../local/lib/glib-2.0/include', '-I../../../../../../local/include', '-I../../../../../../local/include/pixman-1', '-I../../../../../../local/include/freetype2', '-I../../../../../../local/include/libdrm', '-I../../../../../../local/include/libpng16', '-DDISABLE_NLS=1', '-DGETTEXT_PACKAGE="guitarix"', '-DENABLE_NLS=0', '-DHAVE_SNDFILE=1', '-DHAVE_GTHREAD=1', '-DHAVE_GLIBMM=1', '-DHAVE_FFTW3_H=1', '-DHAVE_FFTW3=1', '-DHAVE_JACK=1', '-DHAVE_JACK_SESSION=1', '-DHAVE_GMODULE_EXPORT=1', '-DHAVE_CURL=1', '-DHAVE_GTK2=1', '-DHAVE_GTKMM=1', '-DHAVE_GIOMM=1', '-DHAVE_LADSPA_H=1', '-DHAVE_LRDF=1', '-DHAVE_LILV=1', '-DZITA_CONVOLVER=1', '-DZITA_CONVOLVER_VERSION=4', '-DZITA_RESAMPLER=1', '-DGX_STYLE_DIR="/usr/local/share/gx_head/skins"', '-DGX_FACTORY_DIR="/usr/local/share/gx_head/factorysettings"', '-DGX_SOUND_DIR="/usr/local/share/gx_head/sounds"', '-DGX_SOUND_BPB_DIR="/usr/local/share/gx_head/sounds/bands"', '-DGX_SOUND_BPA_DIR="/usr/local/share/gx_head/sounds/amps"', '-DGX_BUILDER_DIR="/usr/local/share/gx_head/builder"', '-DGX_ICON_DIR="/usr/local/share/guitarix/icons"', '-DGX_PIXMAPS_DIR="/usr/local/share/pixmaps"', '-DGX_VERSION="0.40.0"', '-DOS_64_BIT=1', '-DHAVE_LV2CORE=1', '-DGX_LV2_STYLE_DIR="/usr/local/share/gx_head/skins/LV2"', '-DHAVE_AVAHI_GOBJECT=1', '-DHAVE_AVAHI_GLIB=1', '-DHAVE_AVAHI_CLIENT=1', '-DHAVE_AVAHI=1', '-DHAVE_EIGEN3=1', '-DHAVE_CAIRO=1', '-DHAVE_X11_XLIB_H=1', '-D_THREAD_SAFE', '../src/LV2/xputty/xpngloader.cpp', '-c', '-o/usr/ports/audio/guitarix-lv2/work/guitarix-0.40.0/build/src/LV2/xputty/xpngloader.cpp.1.o', '-fno-omit-frame-pointer', '-I/usr/local/include', '-isystem', '/usr/local/include']
../src/LV2/xputty/xasprintf.cpp:28:11: error: cannot initialize a variable of type 'char *' with an rvalue of type 'void *'
    char *str = malloc((size_t) len + 1);
          ^     ~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.

../src/LV2/xputty/xfilepicker.cpp:194:33: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
    asprintf(&filepicker->path, path);
                                ^~~~
../src/LV2/xputty/xfilepicker.cpp:194:33: note: treat the string as an argument to avoid this
    asprintf(&filepicker->path, path);
                                ^
                                "%s", 
1 warning generated.

Version: 0.40.0
OS: FreeBSD 12
clang-9

Discussion

  • brummer

    brummer - 2020-06-10
    • assigned_to: brummer
     

Anonymous
Anonymous

Add attachments
Cancel