diff options
author | Peter Jones <pjones@redhat.com> | 2007-10-19 15:22:56 +0000 |
---|---|---|
committer | Peter Jones <pjones@redhat.com> | 2007-10-19 15:22:56 +0000 |
commit | 0b7814a745343efbbb64f53775d1594fd5e805c2 (patch) | |
tree | ec687df40f4fbb820c10505c4e4569de38c1de42 | |
parent | 16385c3293ab56651503ccf3e4757214c81ea5a9 (diff) | |
download | anaconda-0b7814a745343efbbb64f53775d1594fd5e805c2.tar.gz anaconda-0b7814a745343efbbb64f53775d1594fd5e805c2.tar.xz anaconda-0b7814a745343efbbb64f53775d1594fd5e805c2.zip |
- close /proc/net/dev when we're done with it.
-rw-r--r-- | ChangeLog | 3 | ||||
-rw-r--r-- | loader2/modules.c | 1 |
2 files changed, 4 insertions, 0 deletions
@@ -2,6 +2,9 @@ * product.py: close /.buildstamp when we're done with it. + * loader2/modules.c (ethCount): close /proc/net/dev when we're done + with it. + 2007-10-19 Chris Lumens <clumens@redhat.com> * isys/nl.c (netlink_interfaces_ip2str, netlink_interfaces_mac2str): diff --git a/loader2/modules.c b/loader2/modules.c index 3a1c69a26..ebe6cba95 100644 --- a/loader2/modules.c +++ b/loader2/modules.c @@ -58,6 +58,7 @@ static int ethCount(const char * type) { fd = open("/proc/net/dev", O_RDONLY); i = read(fd, buf, sizeof(buf) - 1); + close(fd); buf[i] = '\0'; /* skip first two header lines */ |