diff options
Diffstat (limited to 'libports/reallocate-port.c')
-rw-r--r-- | libports/reallocate-port.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/libports/reallocate-port.c b/libports/reallocate-port.c index 4e859a1f..8a9d3601 100644 --- a/libports/reallocate-port.c +++ b/libports/reallocate-port.c @@ -20,7 +20,7 @@ #include "ports.h" #include <hurd/ihash.h> -#include <assert.h> +#include <assert-backtrace.h> void ports_reallocate_port (void *portstruct) @@ -30,11 +30,11 @@ ports_reallocate_port (void *portstruct) int dropref = 0; pthread_mutex_lock (&_ports_lock); - assert (pi->port_right); + assert_backtrace (pi->port_right); err = mach_port_mod_refs (mach_task_self (), pi->port_right, MACH_PORT_RIGHT_RECEIVE, -1); - assert_perror (err); + assert_perror_backtrace (err); pthread_rwlock_wrlock (&_ports_htable_lock); hurd_ihash_locp_remove (&_ports_htable, pi->ports_htable_entry); @@ -43,7 +43,7 @@ ports_reallocate_port (void *portstruct) err = mach_port_allocate (mach_task_self (), MACH_PORT_RIGHT_RECEIVE, &pi->port_right); - assert_perror (err); + assert_perror_backtrace (err); if (pi->flags & PORT_HAS_SENDRIGHTS) { pi->flags &= ~PORT_HAS_SENDRIGHTS; @@ -53,11 +53,11 @@ ports_reallocate_port (void *portstruct) pi->mscount = 0; pthread_rwlock_wrlock (&_ports_htable_lock); err = hurd_ihash_add (&_ports_htable, pi->port_right, pi); - assert_perror (err); + assert_perror_backtrace (err); err = hurd_ihash_add (&pi->bucket->htable, pi->port_right, pi); pthread_rwlock_unlock (&_ports_htable_lock); pthread_mutex_unlock (&_ports_lock); - assert_perror (err); + assert_perror_backtrace (err); /* This is an optimization. It may fail. */ mach_port_set_protected_payload (mach_task_self (), pi->port_right, @@ -65,7 +65,7 @@ ports_reallocate_port (void *portstruct) err = mach_port_move_member (mach_task_self (), pi->port_right, pi->bucket->portset); - assert_perror (err); + assert_perror_backtrace (err); if (dropref) ports_port_deref (pi); |