X-Git-Url: http://git.ozlabs.org/?p=ppp.git;a=blobdiff_plain;f=pppd%2Fsys-sunos4.c;h=8724de55e950486800dc3abba6fe478d3d7bbe9d;hp=2097c8afa5a3eca0f6804bf1bd5d731cd19b3538;hb=26a7a28f129d72feaa08ef589e9a49aafd16d984;hpb=070cf9b22d71b8c3a2cd62c3a2ebcd307f2a53b3 diff --git a/pppd/sys-sunos4.c b/pppd/sys-sunos4.c index 2097c8a..8724de5 100644 --- a/pppd/sys-sunos4.c +++ b/pppd/sys-sunos4.c @@ -26,7 +26,7 @@ */ #ifndef lint -static char rcsid[] = "$Id: sys-sunos4.c,v 1.5 1996/05/27 00:00:56 paulus Exp $"; +static char rcsid[] = "$Id: sys-sunos4.c,v 1.7 1997/03/04 03:43:54 paulus Exp $"; #endif #include @@ -63,6 +63,9 @@ static char rcsid[] = "$Id: sys-sunos4.c,v 1.5 1996/05/27 00:00:56 paulus Exp $" #if defined(sun) && defined(sparc) #include +#ifndef __GNUC__ +extern void *alloca(); +#endif #endif /*sparc*/ static int pppfd; @@ -184,7 +187,7 @@ sys_cleanup() if (ifaddrs[0]) cifaddr(0, ifaddrs[0], ifaddrs[1]); if (default_route_gateway) - cifdefaultroute(0, default_route_gateway); + cifdefaultroute(0, 0, default_route_gateway); if (proxy_arp_addr) cifproxyarp(0, proxy_arp_addr); } @@ -948,7 +951,7 @@ sifnpmode(u, proto, mode) npi[0] = proto; npi[1] = (int) mode; - if (strioctl(pppfd, PPPIO_NPMODE, &npi, 2 * sizeof(int), 0) < 0) { + if (strioctl(pppfd, PPPIO_NPMODE, npi, 2 * sizeof(int), 0) < 0) { syslog(LOG_ERR, "ioctl(set NP %d mode to %d): %m", proto, mode); return 0; } @@ -1021,9 +1024,9 @@ cifaddr(u, o, h) * sifdefaultroute - assign a default route through the address given. */ int -sifdefaultroute(u, g) +sifdefaultroute(u, l, g) int u; - u_int32_t g; + u_int32_t l, g; { struct rtentry rt; @@ -1047,9 +1050,9 @@ sifdefaultroute(u, g) * cifdefaultroute - delete a default route through the address given. */ int -cifdefaultroute(u, g) +cifdefaultroute(u, l, g) int u; - u_int32_t g; + u_int32_t l, g; { struct rtentry rt; @@ -1205,9 +1208,9 @@ get_ether_addr(ipaddr, hwaddr) #define WTMPFILE "/usr/adm/wtmp" -int +void logwtmp(line, name, host) - char *line, *name, *host; + const char *line, *name, *host; { int fd; struct stat buf;