about summary refs log tree commit diff
path: root/sysdeps/generic/ioctl-types.h
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>1996-08-02 05:27:50 +0000
committerRoland McGrath <roland@gnu.org>1996-08-02 05:27:50 +0000
commite75154a665018d5756196275634704c95476ea6b (patch)
tree0c8f889a29304e0cc86611c629f1b620d16cf8a7 /sysdeps/generic/ioctl-types.h
parent9ebb936d991a6e08da05e5a942465d64cac39f86 (diff)
downloadglibc-e75154a665018d5756196275634704c95476ea6b.tar.gz
glibc-e75154a665018d5756196275634704c95476ea6b.tar.xz
glibc-e75154a665018d5756196275634704c95476ea6b.zip
Remade for alpha-1.93 cvs/libc-960802
Diffstat (limited to 'sysdeps/generic/ioctl-types.h')
-rw-r--r--sysdeps/generic/ioctl-types.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/sysdeps/generic/ioctl-types.h b/sysdeps/generic/ioctl-types.h
index 0fc0cd40e1..1116d52e33 100644
--- a/sysdeps/generic/ioctl-types.h
+++ b/sysdeps/generic/ioctl-types.h
@@ -83,6 +83,11 @@ struct winsize
 #endif
 
 #if	defined (TIOCGSIZE) || defined (TIOCSSIZE)
+/* The BSD-style ioctl constructor macros use `sizeof', which can't be used
+   in a preprocessor conditional.  Since the commands are always unique
+   regardless of the size bits, we can safely define away `sizeof' for the
+   purpose of the conditional.  */
+#  define sizeof(type) 0
 #  if defined (TIOCGWINSZ) && TIOCGSIZE == TIOCGWINSZ
 /* Many systems that have TIOCGWINSZ define TIOCGSIZE for source
    compatibility with Sun; they define `struct ttysize' to have identical
@@ -105,6 +110,7 @@ struct ttysize
   int ts_lines, ts_cols;	/* Lines and columns, in characters.  */
 };
 #  endif
+#  undef sizeof			/* See above.  */
 #endif