]> git.wh0rd.org - dump.git/blobdiff - dump/tape.c
Fixed a socket descriptor leak in dump.
[dump.git] / dump / tape.c
index 8c62acb487131841c6ac2db4bdfc01fa627efed5..38dd80426f4a798dd3880c70f917e441834f07d6 100644 (file)
@@ -41,7 +41,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-       "$Id: tape.c,v 1.41 2001/04/10 12:46:53 stelian Exp $";
+       "$Id: tape.c,v 1.42 2001/04/12 13:14:15 stelian Exp $";
 #endif /* not lint */
 
 #include <config.h>
@@ -994,6 +994,8 @@ enslave(void)
                        doslave(cmd[0], i);
                        Exit(X_FINOK);
                }
+               else
+                       close(cmd[0]);
        }
 
 #ifdef LINUX_FORK_BUG