about summary refs log tree commit diff
path: root/hurd/hurdfault.c
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2002-01-02 10:23:33 +0000
committerRoland McGrath <roland@gnu.org>2002-01-02 10:23:33 +0000
commit7595ddb8f97e4262b38e6e2a3c211204581171cc (patch)
tree6251a7cc722edc97d19aa7efe5e64eb91a0b4f3c /hurd/hurdfault.c
parentf58f41f1f479e299a8e61235934befc014992609 (diff)
downloadglibc-7595ddb8f97e4262b38e6e2a3c211204581171cc.tar.gz
glibc-7595ddb8f97e4262b38e6e2a3c211204581171cc.tar.xz
glibc-7595ddb8f97e4262b38e6e2a3c211204581171cc.zip
* hurd/hurdinit.c (_hurd_ports_use): Return error _hurd_ports is null.
	* hurd/hurdsig.c (_hurdsig_init): Conditionalize exception port setup
	for old CMU and new OSF Mach interface flavors.
	* hurd/hurdfault.c (_hurdsig_fault_init): Likewise.
	* sysdeps/mach/hurd/fork.c (__fork): Likewise.

	* hurd/hurdsig.c (_hurd_internal_post_signal): Leave msgh_seqno unset.

	* sysdeps/mach/hurd/spawni.c (__spawni) [KERN_INVALID_LEDGER]:
	Pass extra arguments to task_create for OSF variant.
	* sysdeps/mach/hurd/fork.c (__fork): Likewise.
Diffstat (limited to 'hurd/hurdfault.c')
-rw-r--r--hurd/hurdfault.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/hurd/hurdfault.c b/hurd/hurdfault.c
index 3c17cc0236..e761d36fe1 100644
--- a/hurd/hurdfault.c
+++ b/hurd/hurdfault.c
@@ -1,5 +1,5 @@
 /* Handle faults in the signal thread.
-   Copyright (C) 1994, 1995, 1996, 1997 Free Software Foundation, Inc.
+   Copyright (C) 1994,95,96,97,2002 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -156,8 +156,19 @@ _hurdsig_fault_init (void)
   assert_perror (err);
 
   /* Direct signal thread exceptions to the proc server.  */
+#ifdef THREAD_EXCEPTION_PORT
   err = __thread_set_special_port (_hurd_msgport_thread,
 				   THREAD_EXCEPTION_PORT, sigexc);
+#elif defined (EXC_MASK_ALL)
+  __thread_set_exception_ports (_hurd_msgport_thread,
+				EXC_MASK_ALL & ~(EXC_MASK_SYSCALL
+						 | EXC_MASK_MACH_SYSCALL
+						 | EXC_MASK_RPC_ALERT),
+				sigexc,
+				EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
+#else
+# error thread_set_exception_ports?
+#endif
   __mach_port_deallocate (__mach_task_self (), sigexc);
   assert_perror (err);
 }