mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-11 11:44:03 +02:00
gslice: Tag mem_error() as not returning because it aborts
This should quell some scan-build warnings about code breaking after returning from mem_error() in a weird state. Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
This commit is contained in:
@@ -212,7 +212,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* special helpers to avoid gmessage.c dependency */
|
/* special helpers to avoid gmessage.c dependency */
|
||||||
static void mem_error (const char *format, ...) G_GNUC_PRINTF (1,2);
|
G_NORETURN static void mem_error (const char *format, ...) G_GNUC_PRINTF (1,2) G_ANALYZER_NORETURN;
|
||||||
#define mem_assert(cond) do { if (G_LIKELY (cond)) ; else mem_error ("assertion failed: %s", #cond); } while (0)
|
#define mem_assert(cond) do { if (G_LIKELY (cond)) ; else mem_error ("assertion failed: %s", #cond); } while (0)
|
||||||
|
|
||||||
/* --- structures --- */
|
/* --- structures --- */
|
||||||
|
Reference in New Issue
Block a user