diff options
Diffstat (limited to 'usr.sbin/ppp')
-rw-r--r-- | usr.sbin/ppp/command.c | 25 | ||||
-rw-r--r-- | usr.sbin/ppp/main.c | 18 | ||||
-rw-r--r-- | usr.sbin/ppp/ppp.8 | 7 |
3 files changed, 19 insertions, 31 deletions
diff --git a/usr.sbin/ppp/command.c b/usr.sbin/ppp/command.c index bd5ee7040ae..bfee20e7b20 100644 --- a/usr.sbin/ppp/command.c +++ b/usr.sbin/ppp/command.c @@ -17,7 +17,7 @@ * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. * - * $Id: command.c,v 1.25 1998/01/23 04:34:26 brian Exp $ + * $Id: command.c,v 1.26 1998/01/29 00:34:31 brian Exp $ * */ #include <sys/param.h> @@ -140,24 +140,25 @@ HelpCommand(struct cmdargs const *arg) int IsInteractive(int Display) { - const char *mes = NULL; + const char *m = NULL; if (mode & MODE_DDIAL) - mes = "Working in dedicated dial mode."; + m = "direct dial"; else if (mode & MODE_BACKGROUND) - mes = "Working in background mode."; + m = "background"; else if (mode & MODE_AUTO) - mes = "Working in auto mode."; + m = "auto"; else if (mode & MODE_DIRECT) - mes = "Working in direct mode."; + m = "direct"; else if (mode & MODE_DEDICATED) - mes = "Working in dedicated mode."; - if (mes) { + m = "dedicated"; + else if (mode & MODE_INTER) + m = "interactive"; + if (m) { if (Display && VarTerm) - fprintf(VarTerm, "%s\n", mes); - return 0; + fprintf(VarTerm, "Working in %s mode\n", m); } - return 1; + return mode & MODE_INTER; } static int @@ -845,7 +846,7 @@ TerminalCommand(struct cmdargs const *arg) return (1); } if (VarTerm) { - fprintf(VarTerm, "Enter to terminal mode.\n"); + fprintf(VarTerm, "Entering terminal mode.\n"); fprintf(VarTerm, "Type `~?' for help.\n"); } TtyTermMode(); diff --git a/usr.sbin/ppp/main.c b/usr.sbin/ppp/main.c index 2e7cb521d2e..1a5d5de8029 100644 --- a/usr.sbin/ppp/main.c +++ b/usr.sbin/ppp/main.c @@ -17,7 +17,7 @@ * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. * - * $Id: main.c,v 1.15 1998/01/21 02:13:36 brian Exp $ + * $Id: main.c,v 1.16 1998/01/29 00:34:32 brian Exp $ * * TODO: * o Add commands for traffic summary, version display, etc. @@ -342,15 +342,6 @@ ProcessArgs(int argc, char **argv) return argc == 1 ? *argv : NULL; /* Don't SetLabel yet ! */ } -static void -Greetings(void) -{ - if (VarTerm) { - fprintf(VarTerm, "User Process PPP. Written by Toshiharu OHNO.\n"); - fflush(VarTerm); - } -} - int main(int argc, char **argv) { @@ -409,7 +400,7 @@ main(int argc, char **argv) if (!GetShortHost()) return 1; - Greetings(); + IsInteractive(1); IpcpDefAddress(); if (mode & MODE_INTER) @@ -423,9 +414,7 @@ main(int argc, char **argv) return EX_START; } CleanInterface(IfDevName); - if (mode & MODE_INTER) - fprintf(VarTerm, "Interactive mode\n"); - else if ((mode & MODE_OUTGOING_DAEMON) && !(mode & MODE_DEDICATED)) + if ((mode & MODE_OUTGOING_DAEMON) && !(mode & MODE_DEDICATED)) if (label == NULL) { if (VarTerm) fprintf(VarTerm, "Destination system must be specified in" @@ -1003,7 +992,6 @@ DoLoop(void) netfd = wfd; VarTerm = fdopen(netfd, "a+"); LocalAuthInit(); - Greetings(); IsInteractive(1); Prompt(); } diff --git a/usr.sbin/ppp/ppp.8 b/usr.sbin/ppp/ppp.8 index cbd0c42c3f0..cabcfa542be 100644 --- a/usr.sbin/ppp/ppp.8 +++ b/usr.sbin/ppp/ppp.8 @@ -1,4 +1,4 @@ -.\" $Id: ppp.8,v 1.16 1998/01/20 22:46:30 brian Exp $ +.\" $Id: ppp.8,v 1.17 1998/01/29 00:34:32 brian Exp $ .Dd 20 September 1995 .Os OpenBSD .Dt PPP 8 @@ -2592,7 +2592,6 @@ Get port number if port number is using service name. .Sh HISTORY This program was originally written by Toshiharu OHNO (tony-o@iij.ad.jp), and was submitted to FreeBSD-2.0.5 by Atsushi Murai (amurai@spec.co.jp). -It has since had an enormous face lift and looks substantially different. .Pp -The zlib compression algorithms used in the DEFLATE protocol are provided -thanks to Jean-loup Gailly (Copyright 1995). +It has since been substantially modified by Brian Somers (brian@Awfulhak.org), +and was ported to OpenBSD in November '97 (just after the 2.2 release). |