From 5386b7c76fc0ecf8b05003a5b6daaa33799d506f Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sat, 1 Apr 2023 10:56:40 +0200 Subject: [PATCH] stddef: Fix __need_wint_t handling in case of two stddef.h overrides. * lib/stddef.in.h: Replace _GL_STDDEF_WINT_T with a symbol that depends on the @GUARD_PREFIX@. --- ChangeLog | 6 ++++++ lib/stddef.in.h | 6 +++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index b358a707cf..eea37f348e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2023-04-01 Bruno Haible + + stddef: Fix __need_wint_t handling in case of two stddef.h overrides. + * lib/stddef.in.h: Replace _GL_STDDEF_WINT_T with a symbol that depends + on the @GUARD_PREFIX@. + 2023-03-31 Bruno Haible vasnwprintf: Fix crash upon conversion failure when processing %s. diff --git a/lib/stddef.in.h b/lib/stddef.in.h index c7ce608b98..ddbb74cedb 100644 --- a/lib/stddef.in.h +++ b/lib/stddef.in.h @@ -37,9 +37,9 @@ remember if special invocation has ever been used to obtain wint_t, in which case we need to clean up NULL yet again. */ -# if !(defined _@GUARD_PREFIX@_STDDEF_H && defined _GL_STDDEF_WINT_T) +# if !(defined _@GUARD_PREFIX@_STDDEF_H && defined _@GUARD_PREFIX@_STDDEF_WINT_T) # ifdef __need_wint_t -# define _GL_STDDEF_WINT_T +# define _@GUARD_PREFIX@_STDDEF_WINT_T # endif # @INCLUDE_NEXT@ @NEXT_STDDEF_H@ /* On TinyCC, make sure that the macros that indicate the special invocation @@ -80,7 +80,7 @@ typedef long max_align_t; /* On NetBSD 5.0, the definition of NULL lacks proper parentheses. */ # if (@REPLACE_NULL@ \ - && (!defined _@GUARD_PREFIX@_STDDEF_H || defined _GL_STDDEF_WINT_T)) + && (!defined _@GUARD_PREFIX@_STDDEF_H || defined _@GUARD_PREFIX@_STDDEF_WINT_T)) # undef NULL # ifdef __cplusplus /* ISO C++ says that the macro NULL must expand to an integer constant -- 2.39.5