From: Andre Noll Date: Sat, 20 Jul 2013 19:08:15 +0000 (+0200) Subject: ipc: Close proc fd. X-Git-Tag: v0.5.1~12^2~6 X-Git-Url: http://git.tue.mpg.de/?a=commitdiff_plain;h=a12ecb5d1f128ea7d9dcc6c96f438534d1f43ca7;p=paraslash.git ipc: Close proc fd. We read shmmax only once, so there is no point in keeping this file descriptor open forever. --- diff --git a/ipc.c b/ipc.c index 1ec53c30..89bbe535 100644 --- a/ipc.c +++ b/ipc.c @@ -209,6 +209,7 @@ size_t shm_get_shmmax(void) buf[ret] = '\0'; shmmax = strtoul(buf, NULL, 10); } + close(fd); } } #elif defined SYSCTL_SHMMAX_VARIABLE