mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-27 07:56:14 +01:00
Ignore GCC memory overflow warnings when testing overflows
We know we are overflowing the maximum allocation: it's what we're testing for. https://bugzilla.gnome.org/show_bug.cgi?id=794732
This commit is contained in:
parent
07731ff3fc
commit
327c379862
@ -23,6 +23,8 @@
|
|||||||
|
|
||||||
#ifdef __GNUC__
|
#ifdef __GNUC__
|
||||||
#pragma GCC optimize (1)
|
#pragma GCC optimize (1)
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#pragma GCC diagnostic ignored "-Walloc-size-larger-than="
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "glib.h"
|
#include "glib.h"
|
||||||
@ -198,6 +200,10 @@ empty_alloc (void)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef __GNUC__
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
#endif
|
||||||
|
|
||||||
int
|
int
|
||||||
main (int argc,
|
main (int argc,
|
||||||
char *argv[])
|
char *argv[])
|
||||||
|
Loading…
Reference in New Issue
Block a user