X-Git-Url: http://git.ozlabs.org/?p=ppp.git;a=blobdiff_plain;f=pppd%2Foptions.c;h=3e28def43191926347ffdfeb95559c1c45214000;hp=7d5c71af36117b6e6ceae7290e79e8a54de2337f;hb=f409b9f7b070fc7e0d1839f09d813503d7224df6;hpb=90faf59815262dbb35dc8896d2b040986d140d8f diff --git a/pppd/options.c b/pppd/options.c index 7d5c71a..3e28def 100644 --- a/pppd/options.c +++ b/pppd/options.c @@ -18,7 +18,7 @@ */ #ifndef lint -static char rcsid[] = "$Id: options.c,v 1.54 1999/03/22 05:55:33 paulus Exp $"; +static char rcsid[] = "$Id: options.c,v 1.55 1999/03/24 05:05:24 paulus Exp $"; #endif #include @@ -88,6 +88,7 @@ int idle_time_limit = 0; /* Disconnect if idle for this many seconds */ int holdoff = 30; /* # seconds to pause before reconnecting */ bool notty = 0; /* Stdin/out is not a tty */ char *record_file = NULL; /* File to record chars sent/received */ +int using_pty = 0; extern option_t auth_options[]; @@ -299,7 +300,7 @@ parse_args(argc, argv) /* * scan_args - scan the command line arguments to get the tty name, - * if specified. + * if specified. Also checks whether the notty or pty option was given. */ void scan_args(argc, argv) @@ -314,6 +315,9 @@ scan_args(argc, argv) arg = *argv++; --argc; + if (strcmp(arg, "notty") == 0 || strcmp(arg, "pty") == 0) + using_pty = 1; + /* Skip options and their arguments */ opt = find_option(arg); if (opt != NULL) {