]> git.ozlabs.org Git - ppp.git/blobdiff - pppd/sys-ultrix.c
MD4Update takes bytes not bits! Now the regression test of the README.MSCHAP80
[ppp.git] / pppd / sys-ultrix.c
index 92cde071d2a7907d72357e5a4b7515a8e063d63f..691b38695e8dcee8a52ba9ccce153cbf911cf527 100644 (file)
@@ -21,7 +21,7 @@
  */
 
 #ifndef lint
-static char rcsid[] = "$Id: sys-ultrix.c,v 1.18 1996/07/01 01:20:29 paulus Exp $";
+static char rcsid[] = "$Id: sys-ultrix.c,v 1.23 1998/11/07 06:59:32 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);
 }
@@ -137,14 +137,14 @@ sys_close()
 /*
  * sys_check_options - check the options that the user specified
  */
-void
+int
 sys_check_options()
 {
     if (demand) {
-       fprintf(stderr,
-               "Sorry - demand-dialling is not supported under Ultrix\n");
-       exit(1);
+       option_error("Sorry - demand-dialling is not supported under Ultrix\n");
+       return 0;
     }
+    return 1;
 }
 
 
@@ -563,7 +563,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)
@@ -980,7 +980,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;
 
@@ -1001,7 +1003,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;
 
@@ -1214,6 +1218,16 @@ GetMask(addr)
 }
 
 
+/*
+ * Use the hostid as part of the random number seed.
+ */
+int
+get_host_seed()
+{
+    return gethostid();
+}
+
+
 /*
   Seems like strdup() is not part of string package in Ultrix.
   If I understood the man-page on the sun this should work.
@@ -1250,9 +1264,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;