diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2009-12-21 00:42:19 +0100 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2009-12-21 00:42:19 +0100 |
commit | d9db5347164bd71f5966ae4b88047d50376b0b12 (patch) | |
tree | a769bd974ad47a61fac752fc781c363a084274ad /auth/auth.c | |
parent | 041baa808e57756636411879af8a0a8801680884 (diff) |
Fix spurious newport deallocation
* auth/auth.c (S_auth_server_authenticate): On MIG stub failure,
deallocate the reply port by hand instead of letting the main
message loop do it, since the latter would deallocate newport
too, which we passed to the user.
Diffstat (limited to 'auth/auth.c')
-rw-r--r-- | auth/auth.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/auth/auth.c b/auth/auth.c index 239b4fb3..2afeaf7a 100644 --- a/auth/auth.c +++ b/auth/auth.c @@ -436,10 +436,9 @@ S_auth_server_authenticate (struct authhandle *serverauth, user->egids.ids, user->egids.num, user->agids.ids, user->agids.num); - ports_port_deref (user); if (err) - return err; - + mach_port_deallocate (mach_task_self (), reply); + ports_port_deref (user); mach_port_deallocate (mach_task_self (), rendezvous); return MIG_NO_REPLY; } |