From cca9684f2d7a74fc0b28bfb1859955e0e28d7b4b Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Wed, 3 Aug 2022 11:41:53 +0200 Subject: stdio: Clean up __libc_message after unconditional abort Since commit ec2c1fcefb200c6cb7e09553f3c6af8815013d83 ("malloc: Abort on heap corruption, without a backtrace [BZ #21754]"), __libc_message always terminates the process. Since commit a289ea09ea843ced6e5277c2f2e63c357bc7f9a3 ("Do not print backtraces on fatal glibc errors"), the backtrace facility has been removed. Therefore, remove enum __libc_message_action and the action argument of __libc_message, and mark __libc_message as _No_return. Reviewed-by: Adhemerval Zanella --- include/stdio.h | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'include/stdio.h') diff --git a/include/stdio.h b/include/stdio.h index a6f7fd43cb..c3e772ad9a 100644 --- a/include/stdio.h +++ b/include/stdio.h @@ -143,18 +143,11 @@ extern int __gen_tempname (char *__tmpl, int __suffixlen, int __flags, # define __GT_DIR 1 /* create a directory */ # define __GT_NOCREATE 2 /* just find a name not currently in use */ -enum __libc_message_action -{ - do_message = 0, /* Print message. */ - do_abort = 1 << 0, /* Abort. */ -}; - /* Print out MESSAGE (which should end with a newline) on the error output and abort. */ extern void __libc_fatal (const char *__message) __attribute__ ((__noreturn__)); -extern void __libc_message (enum __libc_message_action action, - const char *__fnt, ...) attribute_hidden; +_Noreturn void __libc_message (const char *__fnt, ...) attribute_hidden; extern void __fortify_fail (const char *msg) __attribute__ ((__noreturn__)); libc_hidden_proto (__fortify_fail) -- cgit 1.4.1