From d85f71ecf4c48baf428da17697b43f2a11129db1 Mon Sep 17 00:00:00 2001 From: OLFDB Date: Tue, 7 Mar 2023 13:41:29 +0100 Subject: Fix: Warnings during build (#1225) * Initial commit * Fix:#1185 * Fix:#1185 * Update after further tests * Update navit.c Missing opening bracket. * Update navit.c Needs AND not OR when combining if clauses. * Revert "Fix:#1185" This reverts commit fd91e400dfc5bfa83ee4565c2ab9e222188eee77. * Revert "Fix:#1185" This reverts commit be87cd30a0b153158bc68b3eb83601aadeda322c. * Fix: Warning during build * WINCE compiler needs pragma to be outside of a function --- navit/debug.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'navit/debug.c') diff --git a/navit/debug.c b/navit/debug.c index e46637cb2..9c615f839 100644 --- a/navit/debug.c +++ b/navit/debug.c @@ -472,6 +472,9 @@ void debug_dump_mallocs(void) { } } + +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wframe-address" // We know what we are doing here, suppress warning void *debug_malloc(const char *where, int line, const char *func, int size) { struct malloc_head *head; struct malloc_tail *tail; @@ -508,7 +511,7 @@ void *debug_malloc(const char *where, int line, const char *func, int size) { tail->magic=0xdeadbef0; return head; } - +#pragma GCC diagnostic pop void *debug_malloc0(const char *where, int line, const char *func, int size) { void *ret=debug_malloc(where, line, func, size); -- cgit v1.2.1