diff options
Diffstat (limited to 'libfshelp')
-rw-r--r-- | libfshelp/fetch-control.c | 3 |
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; } |