]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
hurd: [!__USE_MISC] Do not #undef BSD macros in ioctls
authorSamuel Thibault <samuel.thibault@ens-lyon.org>
Sat, 2 Dec 2023 20:24:58 +0000 (21:24 +0100)
committerSamuel Thibault <samuel.thibault@ens-lyon.org>
Sat, 2 Dec 2023 20:26:50 +0000 (21:26 +0100)
When e.g. including termios.h first and then sys/ioctl.h, without e.g.
_BSD_SOURCE, the latter would #undef e.g. ECHO, without defining it.

sysdeps/mach/hurd/bits/ioctls.h

index 943d5e4287d1f9bbe4a3ada8f97bef647a360aa0..1b2fd6b33fb2d0c81ae2ea42f6f3beade2098052 100644 (file)
@@ -25,6 +25,7 @@
 /* These macros are also defined in <bits/termios.h> (with numerically
    identical values) but this serves to shut up cpp's complaining. */
 
+#ifdef __USE_MISC
 #ifdef NL0
 # undef NL0
 #endif
@@ -82,6 +83,7 @@
 #ifdef NOFLSH
 # undef NOFLSH
 #endif
+#endif
 
 /* Hurd ioctl request are made up of several fields: