summaryrefslogtreecommitdiff
path: root/io.c
diff options
context:
space:
mode:
authorkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-11-12 02:29:37 +0000
committerkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-11-12 02:29:37 +0000
commit791f5449c170467ebe7f43d06047ec3d61d141eb (patch)
tree553a4f5782f752c6b7d0e489a912a2b165815ffe /io.c
parentb3027d5929945a7d08b89af3bb514c9b687b41d0 (diff)
* io.c (ioctl_narg_len): Linux doesn't have IOCPARM_LEN macro, but
has _IOC_SIZE. support it. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33718 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r--io.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/io.c b/io.c
index 38638a18db..a351737877 100644
--- a/io.c
+++ b/io.c
@@ -7908,6 +7908,8 @@ ioctl_narg_len(int cmd)
#endif
#ifdef IOCPARM_LEN
len = IOCPARM_LEN(cmd); /* on BSDish systems we're safe */
+#elif defined(_IOC_SIZE)
+ len = _IOC_SIZE(cmd);
#else
len = 256; /* otherwise guess at what's safe */
#endif