]> git.ozlabs.org Git - ppp.git/blobdiff - pppd/tty.c
Call sys_close in the child when starting charshunt to make sure
[ppp.git] / pppd / tty.c
index f2454279fedb5b17d10af6630b69e1b0c457a68a..57f7465c48ceaf8c242d32d6a0de93e812432d02 100644 (file)
@@ -20,7 +20,7 @@
  * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  */
 
-#define RCSID  "$Id: tty.c,v 1.5 2001/03/08 05:11:16 paulus Exp $"
+#define RCSID  "$Id: tty.c,v 1.7 2002/09/12 22:34:47 paulus Exp $"
 
 #include <stdio.h>
 #include <ctype.h>
@@ -197,6 +197,8 @@ struct channel tty_channel = {
        &tty_check_options,
        &connect_tty,
        &disconnect_tty,
+       &tty_establish_ppp,
+       &tty_disestablish_ppp,
        &tty_do_send_config,
        &tty_recv_config,
        &cleanup_tty,
@@ -839,6 +841,7 @@ start_charshunt(ifd, ofd)
        if (getuid() != uid)
            fatal("setuid failed");
        setgid(getgid());
+       sys_close();
        if (!nodetach)
            log_to_fd = -1;
        charshunt(ifd, ofd, record_file);