From: H.J. Lu Date: Mon, 16 Dec 2024 21:51:07 +0000 (+0800) Subject: tst-atexit-common.c: Mark _exit_with_flush as noreturn X-Git-Tag: glibc-2.41~334 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=560cfeb82693912723ff0e11232c86f9b492a1a0;p=thirdparty%2Fglibc.git tst-atexit-common.c: Mark _exit_with_flush as noreturn Mark _exit_with_flush as noreturn to silence the Clang error on tst-atexit-common.c: In file included from tst-atexit.c:22: ../stdlib/tst-atexit-common.c:113:5: error: unannotated fall-through between switch labels [-Werror,-Wimplicit-fallthrough] 113 | case 0: /* Child. */ | ^ ../stdlib/tst-atexit-common.c:113:5: note: insert 'break;' to avoid fall-through 113 | case 0: /* Child. */ | ^ | break; 1 error generated. Signed-off-by: H.J. Lu Reviewed-by: Sam James --- diff --git a/stdlib/tst-atexit-common.c b/stdlib/tst-atexit-common.c index 4bea464b19..f77ccbbd0d 100644 --- a/stdlib/tst-atexit-common.c +++ b/stdlib/tst-atexit-common.c @@ -37,6 +37,7 @@ static char crumbs[sizeof (expected)]; static int next_slot = 0; /* Helper: flush stdout and _exit. */ +__attribute__ ((__noreturn__)) static void _exit_with_flush (int code) {