bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: strerror_r breakage on mingw


From: Bruno Haible
Subject: Re: strerror_r breakage on mingw
Date: Fri, 05 May 2017 00:09:41 +0200
User-agent: KMail/5.1.3 (Linux/4.4.0-75-generic; KDE/5.18.0; x86_64; ; )

> >     Fix conflict between strerror_r-posix module and AC_FUNC_STRERROR_R.
> >     * modules/strerror_r-posix (configure.ac): Invoke gl_MODULE_INDICATOR.
> >     * lib/error.c: Test GNULIB_STRERROR_R_POSIX before testing
> >     HAVE_DECL_STRERROR_R, HAVE_STRERROR_R, or STRERROR_R_CHAR_P.
> >     * lib/argp-help.c (__argp_failure): Likewise.
> 
> Oops, there was a mistake in this patch. Fixing it as follows:

Oops, the same mistake occurred twice. Fixing the second one as follows:


2017-05-04 Bruno Haible  <address@hidden>

        argp: Fix mistake in 2017-04-23 commit.
        * lib/argp-help.c (__argp_failure): If GNULIB_STRERROR_R_POSIX is set,
        assume that strerror_r returns 'int', not 'char *'.

diff --git a/lib/argp-help.c b/lib/argp-help.c
index 05ab474..0632960 100644
--- a/lib/argp-help.c
+++ b/lib/argp-help.c
@@ -1874,7 +1874,7 @@ __argp_failure (const struct argp_state *state, int 
status, int errnum,
               putc_unlocked (':', stream);
               putc_unlocked (' ', stream);
 # if GNULIB_STRERROR_R_POSIX || HAVE_DECL_STRERROR_R
-#  if GNULIB_STRERROR_R_POSIX || STRERROR_R_CHAR_P
+#  if !GNULIB_STRERROR_R_POSIX && STRERROR_R_CHAR_P
               s = __strerror_r (errnum, buf, sizeof buf);
 #  else
               if (__strerror_r (errnum, buf, sizeof buf) == 0)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]