aboutsummaryrefslogtreecommitdiff
path: root/libnetfs
diff options
context:
space:
mode:
Diffstat (limited to 'libnetfs')
-rw-r--r--libnetfs/io-restrict-auth.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libnetfs/io-restrict-auth.c b/libnetfs/io-restrict-auth.c
index e1fe79da..4ee77356 100644
--- a/libnetfs/io-restrict-auth.c
+++ b/libnetfs/io-restrict-auth.c
@@ -48,6 +48,7 @@ netfs_S_io_restrict_auth (struct protid *user,
{
*newport = ports_get_right (newpi);
*newporttype = MACH_MSG_TYPE_MAKE_SEND;
+ ports_port_deref (newpi);
}
else
{
@@ -56,6 +57,5 @@ netfs_S_io_restrict_auth (struct protid *user,
err = ENOMEM;
}
- ports_port_deref (newpi);
return err;
}