From bfd0179474b338eff846b409e3775362fc374451 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Wed, 12 Aug 2020 02:42:32 +0200 Subject: [PATCH] thread-optim: Fix a compiler warning. * lib/thread-optim.h (IF_MT_DECL): Define differently. --- ChangeLog | 5 +++++ lib/thread-optim.h | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 5c17b05cb2..380ca474e9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2020-08-11 Bruno Haible + + thread-optim: Fix a compiler warning. + * lib/thread-optim.h (IF_MT_DECL): Define differently. + 2020-08-11 Bruno Haible Use __restrict also on clang. diff --git a/lib/thread-optim.h b/lib/thread-optim.h index 5d9a499825..0cdcfeccd1 100644 --- a/lib/thread-optim.h +++ b/lib/thread-optim.h @@ -53,7 +53,7 @@ # define IF_MT_DECL char optimize_for_single_thread = __libc_single_threaded # define IF_MT if (!optimize_for_single_thread) #else -# define IF_MT_DECL (void *)0 +# define IF_MT_DECL (void)0 # define IF_MT #endif -- 2.39.5