mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-08-28 11:31:16 +00:00
m4: Don't suggest attribute malloc
With glib inclusion, some of its functions have __attribute__((__malloc__)) which make compiler realize we want to use the same attribute for some trivial functions of ours. For instance qemuDomainManagedSavePath(). I don't see any real benefit into using the attribute, so disable that suggestion. In fact, wrong use of the attribute may lead to mysterious bugs: https://gitlab.gnome.org/GNOME/glib/issues/1465 Signed-off-by: Michal Privoznik <mprivozn@redhat.com> ACKed-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
71519d4638
commit
0ad79c1d01
@ -126,6 +126,7 @@ AC_DEFUN([LIBVIRT_COMPILE_WARNINGS],[
|
|||||||
dontwarn="$dontwarn -Wunused-macros"
|
dontwarn="$dontwarn -Wunused-macros"
|
||||||
dontwarn="$dontwarn -Woverlength-strings"
|
dontwarn="$dontwarn -Woverlength-strings"
|
||||||
dontwarn="$dontwarn -Wstack-protector"
|
dontwarn="$dontwarn -Wstack-protector"
|
||||||
|
dontwarn="$dontwarn -Wsuggest-attribute=malloc"
|
||||||
|
|
||||||
# Get all possible GCC warnings
|
# Get all possible GCC warnings
|
||||||
gl_MANYWARN_ALL_GCC([maybewarn])
|
gl_MANYWARN_ALL_GCC([maybewarn])
|
||||||
|
Loading…
Reference in New Issue
Block a user