diff options
author | Bernd Eckenfels <net-tools@lina.inka.de> | 2001-02-19 21:42:43 +0000 |
---|---|---|
committer | Bernd Eckenfels <net-tools@lina.inka.de> | 2001-02-19 21:42:43 +0000 |
commit | 85d64cda0795e307e154d76053b4dece4be49bbd (patch) | |
tree | f2e47e97c0ae37edb8ed2a1f36c808238b651571 /ifconfig.c | |
parent | 3eee4d430c7b3665dae29c7279a49973428079d7 (diff) | |
download | net-tools-85d64cda0795e307e154d76053b4dece4be49bbd.tar.gz net-tools-85d64cda0795e307e154d76053b4dece4be49bbd.tar.bz2 net-tools-85d64cda0795e307e154d76053b4dece4be49bbd.zip |
Adam Richter pointed out, that 0 is a valid fd value, even if it is unlikely
to be the case in this situation.
Diffstat (limited to 'ifconfig.c')
-rw-r--r-- | ifconfig.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -3,7 +3,7 @@ * that either displays or sets the characteristics of * one or more of the system's networking interfaces. * - * Version: $Id: ifconfig.c,v 1.44 2001/02/12 21:06:47 pb Exp $ + * Version: $Id: ifconfig.c,v 1.45 2001/02/19 21:42:43 ecki Exp $ * * Author: Fred N. van Kempen, <waltje@uwalt.nl.mugnet.org> * and others. Copyright 1993 MicroWalt Corporation @@ -318,7 +318,7 @@ int main(int argc, char **argv) perror("family socket"); exit(1); } else { - if (skfd > 0 && skfd != fd) close(skfd); + if (skfd >= 0 && skfd != fd) close(skfd); skfd = fd; } } |