about summary refs log tree commit diff
path: root/sysdeps/mach
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>1995-12-04 17:10:03 +0000
committerRoland McGrath <roland@gnu.org>1995-12-04 17:10:03 +0000
commit99cf7e3ebaa2d779c96bc2fa9a4770ef032d58da (patch)
treea6f894b82c45881ad7e960ff2d5600f5cd531b6d /sysdeps/mach
parent683158e0c42dc68e3c43a32b6e5d832c5280e94e (diff)
downloadglibc-99cf7e3ebaa2d779c96bc2fa9a4770ef032d58da.tar.gz
glibc-99cf7e3ebaa2d779c96bc2fa9a4770ef032d58da.tar.xz
glibc-99cf7e3ebaa2d779c96bc2fa9a4770ef032d58da.zip
For IOC_VOID request, send ARG itself as integer_t arg in RPC.
Diffstat (limited to 'sysdeps/mach')
-rw-r--r--sysdeps/mach/hurd/ioctl.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/sysdeps/mach/hurd/ioctl.c b/sysdeps/mach/hurd/ioctl.c
index a1523c6c4d..7c58270f55 100644
--- a/sysdeps/mach/hurd/ioctl.c
+++ b/sysdeps/mach/hurd/ioctl.c
@@ -171,6 +171,13 @@ DEFUN(__ioctl, (fd, request),
       in (_IOT_COUNT1 (type), _IOT_TYPE1 (type));
       in (_IOT_COUNT2 (type), _IOT_TYPE2 (type));
     }
+  else if (_IOC_INOUT (request) == IOC_VOID)
+    {
+      /* The RPC takes a single integer_t argument.
+	 Rather than pointing to the value, ARG is the value itself.  */
+      *t++ = io2mach_type (_IOTS (integer_t));
+      *((integer_t *) t)++ = (integer_t) arg;
+    }
 
   /* Compute the expected size of the reply.  There is a standard header
      consisting of the message header and the reply code.  Then, for out