]> git.ozlabs.org Git - ppp.git/blobdiff - pppd/tty.c
Don't close pty_slave and real_ttyfd in connect_tty if an error
[ppp.git] / pppd / tty.c
index a911fde5c0f0b34f274a56763f8d075aa98f67f2..c11d039364420c97093f00bc370649f550610f7e 100644 (file)
@@ -68,7 +68,7 @@
  * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-#define RCSID  "$Id: tty.c,v 1.22 2004/11/13 12:07:29 paulus Exp $"
+#define RCSID  "$Id: tty.c,v 1.23 2004/12/31 11:49:22 paulus Exp $"
 
 #include <stdio.h>
 #include <ctype.h>
@@ -755,14 +755,6 @@ int connect_tty()
                close(pty_master);
                pty_master = -1;
        }
-       if (pty_slave >= 0) {
-               close(pty_slave);
-               pty_slave = -1;
-       }
-       if (real_ttyfd >= 0) {
-               close(real_ttyfd);
-               real_ttyfd = -1;
-       }
        ttyfd = -1;
        if (got_sigterm)
                asked_to_quit = 1;