* lib/xstdopen.c (xstdopen): Improve error message. Ignore the errno
value.
+2024-12-17 Bruno Haible <bruno@clisp.org>
+
+ xstdopen: Improve error message.
+ * lib/xstdopen.c (xstdopen): Improve error message. Ignore the errno
+ value.
+
2024-12-10 Bruno Haible <bruno@clisp.org>
openat-die: Fix a gcc -Wformat -Wformat-security warning.
{
int stdopen_errno = stdopen ();
if (stdopen_errno != 0)
- error (exit_failure, stdopen_errno, _("standard file descriptors"));
+ /* Ignore stdopen_errno in the error message, since it may be misleading
+ (see stdopen.c). */
+ error (exit_failure, 0,
+ _("failed to open all three standard file descriptors; maybe %s or %s are not working right?"),
+ "/dev/null", "/dev/full");
}