bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH hurd 2/7] libdiskfs: fix port leak


From: Justus Winter
Subject: [PATCH hurd 2/7] libdiskfs: fix port leak
Date: Sat, 17 Jan 2015 18:26:41 +0100

* libdiskfs/boot-start.c (get_console): Deallocate `device_master'.
---
 libdiskfs/boot-start.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libdiskfs/boot-start.c b/libdiskfs/boot-start.c
index cfe2303..9be8ed2 100644
--- a/libdiskfs/boot-start.c
+++ b/libdiskfs/boot-start.c
@@ -61,6 +61,7 @@ get_console ()
     return MACH_PORT_NULL;
 
   err = device_open (device_master, D_WRITE | D_READ, "console", &console);
+  mach_port_deallocate (mach_task_self (), device_master);
   if (err)
     return MACH_PORT_NULL;
 
-- 
2.1.4




reply via email to

[Prev in Thread] Current Thread [Next in Thread]