summaryrefslogtreecommitdiff
path: root/libnetfs
diff options
context:
space:
mode:
authorMichael I. Bushnell <mib@gnu.org>1995-12-15 17:01:37 +0000
committerMichael I. Bushnell <mib@gnu.org>1995-12-15 17:01:37 +0000
commitb4834e5a4386363acca86fdd6c118c0389256933 (patch)
tree1cc7be0cc6ded5ee6e8b4be9fd0cd885939299f7 /libnetfs
parent230860084c59fa0b6363b5f45761de30d97e92b3 (diff)
Formerly dir-rename.c.~2~
Diffstat (limited to 'libnetfs')
-rw-r--r--libnetfs/dir-rename.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libnetfs/dir-rename.c b/libnetfs/dir-rename.c
index b804393c..6950e78e 100644
--- a/libnetfs/dir-rename.c
+++ b/libnetfs/dir-rename.c
@@ -34,8 +34,10 @@ netfs_S_dir_rename (struct protid *fromdiruser, char *fromname,
return EXDEV;
/* Note that nothing is locked here */
- return netfs_attempt_rename (fromdiruser->credential, fromdiruser->po->np,
- fromname, todiruser->po->np, toname);
+ err = netfs_attempt_rename (fromdiruser->credential, fromdiruser->po->np,
+ fromname, todiruser->po->np, toname);
+ if (!err)
+ mach_port_deallocate (mach_task_self (), todiruser->pi.port_right);
}