diff options
author | Miles Bader <miles@gnu.org> | 1997-02-14 01:23:47 +0000 |
---|---|---|
committer | Miles Bader <miles@gnu.org> | 1997-02-14 01:23:47 +0000 |
commit | fec506ebc6c526b9aad8b10840a3a346f8d27f37 (patch) | |
tree | f9bb96b39690f55b8b4a1343a87890a208312de1 /libdiskfs | |
parent | d2f2436ff2fdeb3d6c8f4db78a88883901600994 (diff) |
(diskfs_S_fsys_getroot):
Pass a prototype peropen instead of the dotdotport and depth to
diskfs_make_peropen.
Diffstat (limited to 'libdiskfs')
-rw-r--r-- | libdiskfs/fsys-getroot.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/libdiskfs/fsys-getroot.c b/libdiskfs/fsys-getroot.c index ea5759b5..2a18810c 100644 --- a/libdiskfs/fsys-getroot.c +++ b/libdiskfs/fsys-getroot.c @@ -46,7 +46,8 @@ diskfs_S_fsys_getroot (fsys_t controlport, mode_t type; struct protid *newpi; struct iouser user; - + struct peropen peropen_context = { root_parent: dotdot }; + if (!pt) return EOPNOTSUPP; @@ -71,10 +72,8 @@ diskfs_S_fsys_getroot (fsys_t controlport, || fshelp_translated (&diskfs_root_node->transbox)) && !(flags & O_NOTRANS)) { - struct diskfs_trans_callback_cookie2 cookie2 = { dotdot, 0 }; - error = fshelp_fetch_root (&diskfs_root_node->transbox, - &cookie2, dotdot, &user, flags, + &peropen_context, dotdot, &user, flags, _diskfs_translator_callback1, _diskfs_translator_callback2, retry, retryname, returned_port); @@ -172,10 +171,13 @@ diskfs_S_fsys_getroot (fsys_t controlport, flags &= ~OPENONLY_STATE_MODES; - error = diskfs_create_protid (diskfs_make_peropen (diskfs_root_node, - flags, dotdot, 0), - &user, &newpi); + error = + diskfs_create_protid (diskfs_make_peropen (diskfs_root_node, flags, + &peropen_context), + &user, &newpi); + mach_port_deallocate (mach_task_self (), dotdot); + if (! error) { *retry = FS_RETRY_NORMAL; |