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:
Philip Withnall 2022-11-18 16:36:47 +00:00
parent 0781e12f45
commit 146a0a001d

View File

@ -212,7 +212,7 @@
#endif
/* 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)
/* --- structures --- */