diff options
author | Roland McGrath <roland@gnu.org> | 1995-01-19 07:29:37 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 1995-01-19 07:29:37 +0000 |
commit | 33b8c87b89ac9a8cc821f34f0e1a18b3c6def1be (patch) | |
tree | ebc6eedbf3f22e5183f9866bb19bee80956c62f2 /libdiskfs | |
parent | 8709cd55045bccb58a7b1ebe23216697ed5a03a7 (diff) |
Updated to new io_select protocol.
Diffstat (limited to 'libdiskfs')
-rw-r--r-- | libdiskfs/io-select.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/libdiskfs/io-select.c b/libdiskfs/io-select.c index 2e8f636d..e29e2a67 100644 --- a/libdiskfs/io-select.c +++ b/libdiskfs/io-select.c @@ -1,5 +1,5 @@ /* - Copyright (C) 1994 Free Software Foundation + Copyright (C) 1994, 1995 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as @@ -22,25 +22,22 @@ /* Implement io_select as described in <hurd/io.defs>. */ kern_return_t diskfs_S_io_select (struct protid *cred, - int type, - mach_port_t port, - mach_msg_type_name_t porttype, - int tag, - int *possible) + int *type, + int *tag) { if (!cred) return EOPNOTSUPP; mutex_lock (&cred->po->np->lock); - if (((type & SELECT_READ) && !(cred->po->openstat & O_READ)) - || ((type & SELECT_WRITE) && !(cred->po->openstat & O_WRITE))) + if (((*type & SELECT_READ) && !(cred->po->openstat & O_READ)) + || ((*type & SELECT_WRITE) && !(cred->po->openstat & O_WRITE))) { mutex_unlock (&cred->po->np->lock); return EBADF; } mutex_unlock (&cred->po->np->lock); - /* Select is always possible */ + /* Select is always possible. */ mach_port_deallocate (mach_task_self (), port); - *possible = type & ~SELECT_URG; + *type &= ~SELECT_URG; return 0; } |