X-Git-Url: http://git.ozlabs.org/?p=ppp.git;a=blobdiff_plain;f=pppd%2Fsys-ultrix.c;h=43fd115136371f246183337fe0f20ff6d1b880f9;hp=ec05e7fb75d7e4d98122a56a1b9b7125bbad2859;hb=e28f47d5e53abe7317d9a82703bbbee044482d4f;hpb=7173a14a57e110a75b316d0ad6de58f2eea5057c diff --git a/pppd/sys-ultrix.c b/pppd/sys-ultrix.c index ec05e7f..43fd115 100644 --- a/pppd/sys-ultrix.c +++ b/pppd/sys-ultrix.c @@ -21,7 +21,7 @@ */ #ifndef lint -static char rcsid[] = "$Id: sys-ultrix.c,v 1.17 1996/05/26 23:58:03 paulus Exp $"; +static char rcsid[] = "$Id: sys-ultrix.c,v 1.21 1997/04/30 05:59:38 paulus Exp $"; #endif /* @@ -116,7 +116,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); } @@ -141,8 +141,7 @@ void sys_check_options() { if (demand) { - fprintf(stderr, - "Sorry - demand-dialling is not supported under Ultrix\n"); + option_error("Sorry - demand-dialling is not supported under Ultrix\n"); exit(1); } } @@ -563,7 +562,7 @@ output(unit, p, len) int len; { if (debug) - log_packet(p, len, "sent "); + log_packet(p, len, "sent ", LOG_DEBUG); if (write(ttyfd, p, len) < 0) { if (errno != EIO) @@ -599,6 +598,7 @@ wait_input(timo) * loopback, for the length of time specified by *timo (indefinite * if timo is NULL). */ +void wait_loop_output(timo) struct timeval *timo; { @@ -610,6 +610,7 @@ wait_loop_output(timo) * wait_time - wait for a given length of time or until a * signal is received. */ +void wait_time(timo) struct timeval *timo; { @@ -803,31 +804,6 @@ get_idle_time(u, ip) } -/* - * set_filters - transfer the pass and active filters to the kernel. - */ -int -set_filters(pass, active) - struct bpf_program *pass, *active; -{ - int ret = 1; - - if (pass->bf_len > 0) { - if (ioctl(ppp_fd, PPPIOCSPASS, pass) < 0) { - syslog(LOG_ERR, "Couldn't set pass-filter in kernel: %m"); - ret = 0; - } - } - if (active->bf_len > 0) { - if (ioctl(ppp_fd, PPPIOCSACTIVE, active) < 0) { - syslog(LOG_ERR, "Couldn't set active-filter in kernel: %m"); - ret = 0; - } - } - return ret; -} - - /* * sifvjcomp - config tcp header compression */ @@ -1003,7 +979,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 l, g; { struct rtentry rt; @@ -1024,7 +1002,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 l, g; { struct rtentry rt; @@ -1273,9 +1253,9 @@ char *strdup( in ) char *in; #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;