This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
[PATCH,HURD]: Drop spurious mach_port_deallocate call
- From: Samuel Thibault <samuel dot thibault at ens-lyon dot org>
- To: Roland McGrath <roland at redhat dot com>, libc-alpha at sources dot redhat dot com
- Date: Sun, 20 Dec 2009 21:59:40 +0100
- Subject: [PATCH,HURD]: Drop spurious mach_port_deallocate call
Hello,
The patch below fixes a spurious call to mach_port_deallocate: rootdevid
is already deallocated as soon as it is fetched through __io_identity.
Samuel
2009-12-20 Samuel Thibault <samuel.thibault@ens-lyon.org>
* sysdeps/mach/hurd/getcwd.c (cleanup): Do not call
__mach_port_deallocate on rootdevid.
diff --git a/sysdeps/mach/hurd/getcwd.c b/sysdeps/mach/hurd/getcwd.c
index 7e07e6b..f833f3d 100644
--- a/sysdeps/mach/hurd/getcwd.c
+++ b/sysdeps/mach/hurd/getcwd.c
@@ -60,7 +60,6 @@ _hurd_canonicalize_directory_name_internal (file_t thisdir,
__mach_port_deallocate (__mach_task_self (), thisid);
__mach_port_deallocate (__mach_task_self (), thisdevid);
__mach_port_deallocate (__mach_task_self (), rootid);
- __mach_port_deallocate (__mach_task_self (), rootdevid);
if (dirbuf != NULL)
__vm_deallocate (__mach_task_self (),