about summary refs log tree commit diff
path: root/sysdeps/mach/hurd/fork.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/mach/hurd/fork.c')
-rw-r--r--sysdeps/mach/hurd/fork.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/sysdeps/mach/hurd/fork.c b/sysdeps/mach/hurd/fork.c
index 8c6ef12d10..8d730ae4fb 100644
--- a/sysdeps/mach/hurd/fork.c
+++ b/sysdeps/mach/hurd/fork.c
@@ -252,6 +252,12 @@ __fork (void)
 		      if (old != MACH_PORT_NULL)
 			/* XXX what to do here? */
 			__mach_port_deallocate (__mach_task_self (), old);
+		      /* The new task will receive its own exceptions
+			 on its message port.  */
+		      if (err = __task_set_special_port (newtask,
+							 TASK_EXCEPTION_PORT,
+							 port))
+			LOSE;
 		    }
 		  if (err = __mach_port_insert_right (newtask,
 						      portnames[i],