diff options
author | Michael I. Bushnell <mib@gnu.org> | 1994-02-04 22:03:48 +0000 |
---|---|---|
committer | Michael I. Bushnell <mib@gnu.org> | 1994-02-04 22:03:48 +0000 |
commit | 43fc92da2baf9095b8b9dd170afc41a5007cc565 (patch) | |
tree | d4f07d1661571f573df0ede904336b444778706f | |
parent | c6191e3f76d7625699517ff5bf457dc515c4b658 (diff) |
Formerly io-read.c.~4~
-rw-r--r-- | libdiskfs/io-read.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/libdiskfs/io-read.c b/libdiskfs/io-read.c index d38ae31f..b21ee7f1 100644 --- a/libdiskfs/io-read.c +++ b/libdiskfs/io-read.c @@ -17,6 +17,7 @@ #include "priv.h" #include "io_S.h" +#include <fcntl.h> /* Implement io_read as described in <hurd/io.defs>. */ error_t @@ -41,11 +42,9 @@ diskfs_S_io_read (struct protid *cred, if (maxread < 0) return EINVAL; - mutex_lock (&np->i_toplock); + mutex_lock (&np->lock); - err = ioserver_get_conch (&np->i_conch); - if (err) - goto out; + ioserver_get_conch (&np->conch); if (off == -1) off = cred->po->filepointer; @@ -72,7 +71,6 @@ diskfs_S_io_read (struct protid *cred, if (err && ourbuf) vm_deallocate (mach_task_self (), (u_int) buf, maxread); - out: - mutex_unlock (&np->i_toplock); + mutex_unlock (&np->lock); return err; } |