X-Git-Url: https://git.ozlabs.org/?p=ppp.git;a=blobdiff_plain;f=pppd%2Fmain.c;h=35bc8ea4b27e57157084b65ccffd88f16a6869d3;hp=6ec6eab29323094193a6782a19cec58ba6e73dad;hb=eff1bf74317aeed1a98d141f8cf0aec6c8756162;hpb=0e4cda76e8dafc931c41aedbfc1bd5ea92f9635f diff --git a/pppd/main.c b/pppd/main.c index 6ec6eab..35bc8ea 100644 --- a/pppd/main.c +++ b/pppd/main.c @@ -18,7 +18,7 @@ */ #ifndef lint -static char rcsid[] = "$Id: main.c,v 1.14 1994/08/09 06:27:52 paulus Exp $"; +static char rcsid[] = "$Id: main.c,v 1.15 1994/08/22 00:40:48 paulus Exp $"; #endif #include @@ -99,7 +99,7 @@ static pid_t pid; /* Our pid */ static pid_t pgrpid; /* Process Group ID */ uid_t uid; /* Our real user-id */ -char devname[MAXPATHLEN] = "/dev/tty"; /* Device name */ +char devnam[MAXPATHLEN] = "/dev/tty"; /* Device name */ int default_device = TRUE; /* use default device (stdin/out) */ int fd = -1; /* Device file descriptor */ @@ -208,7 +208,7 @@ main(argc, argv) p = ttyname(0); if (p) - strcpy(devname, p); + strcpy(devnam, p); if (gethostname(hostname, MAXNAMELEN) < 0 ) { perror("couldn't get hostname"); @@ -316,7 +316,7 @@ main(argc, argv) * Lock the device if we've been asked to. */ if (lockflag && !default_device) - if (lock(devname) < 0) + if (lock(devnam) < 0) die(1); do { @@ -324,8 +324,8 @@ main(argc, argv) /* * Open the serial device and set it up to be the ppp interface. */ - if ((fd = open(devname, O_RDWR, 0)) < 0) { - syslog(LOG_ERR, "open(%s): %m", devname); + if ((fd = open(devnam, O_RDWR, 0)) < 0) { + syslog(LOG_ERR, "open(%s): %m", devnam); die(1); } hungup = 0; @@ -391,7 +391,7 @@ main(argc, argv) * Block all signals, start opening the connection, and wait for * incoming events (reply, timeout, etc.). */ - syslog(LOG_NOTICE, "Connect: %s <--> %s", ifname, devname); + syslog(LOG_NOTICE, "Connect: %s <--> %s", ifname, devnam); lcp_lowerup(0); lcp_open(0); /* Start protocol */ for (phase = PHASE_ESTABLISH; phase != PHASE_DEAD; ) {