summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael I. Bushnell <mib@gnu.org>1995-06-20 00:10:40 +0000
committerMichael I. Bushnell <mib@gnu.org>1995-06-20 00:10:40 +0000
commit9436d05db118701702c18217b8d3f052f7eefd1e (patch)
treee3bb0fc2ea357e5b5ed2f14e01412e2e5a12f860
parenta84a89815f6c2f6581332c0adece2695e33b4382 (diff)
(fshelp_fetch_control): Only frob refs if control is non-null.
-rw-r--r--libfshelp/fetch-control.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libfshelp/fetch-control.c b/libfshelp/fetch-control.c
index 32b28ddf..26c12d88 100644
--- a/libfshelp/fetch-control.c
+++ b/libfshelp/fetch-control.c
@@ -25,6 +25,7 @@ fshelp_fetch_control (struct transbox *box,
mach_port_t *control)
{
*control = box->active;
- mach_port_mod_refs (mach_task_self (), *control, MACH_PORT_RIGHT_SEND, 1);
+ if (*control != MACH_PORT_NULL)
+ mach_port_mod_refs (mach_task_self (), *control, MACH_PORT_RIGHT_SEND, 1);
return 0;
}