]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Use typedef in definition of warning_hook
authorTom Tromey <tromey@adacore.com>
Tue, 13 Feb 2024 20:20:22 +0000 (13:20 -0700)
committerTom Tromey <tromey@adacore.com>
Wed, 14 Feb 2024 11:59:35 +0000 (04:59 -0700)
This changes the global 'warning_hook' to use the warning_hook_handler
typedef in its definition.  This makes it a little easier to change
the type, should that be needed.

gdb/utils.c

index a1aeb1025fa0945062c183105987e402b7d17e9e..68aebf373819cbcb9e8f82b6c807d8fdfe291e50 100644 (file)
@@ -131,7 +131,7 @@ show_pagination_enabled (struct ui_file *file, int from_tty,
 /* Warning hook pointer.  This has to be 'static' to avoid link
    problems with thread-locals on AIX.  */
 
-static thread_local void (*warning_hook) (const char *, va_list);
+static thread_local warning_hook_handler warning_hook;
 
 /* See utils.h.  */