]> git.ozlabs.org Git - ppp.git/blobdiff - pppd/sys-ultrix.c
This commit was manufactured by cvs2svn to create tag
[ppp.git] / pppd / sys-ultrix.c
index 95bb7dd4721dc021ef2d9c72a23e5a5e42cad254..cb1303bad47fa5c015e13ca245c8c57b5b0178c7 100644 (file)
@@ -21,7 +21,7 @@
  */
 
 #ifndef lint
-static char rcsid[] = "$Id: sys-ultrix.c,v 1.20 1997/03/04 03:43:54 paulus Exp $";
+static char rcsid[] = "$Id: sys-ultrix.c,v 1.24 1999/03/08 01:46:24 paulus Exp $";
 #endif
 
 /*
@@ -137,13 +137,14 @@ sys_close()
 /*
  * sys_check_options - check the options that the user specified
  */
-void
+int
 sys_check_options()
 {
     if (demand) {
        option_error("Sorry - demand-dialling is not supported under Ultrix\n");
-       exit(1);
+       return 0;
     }
+    return 1;
 }
 
 
@@ -562,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 +981,7 @@ cifaddr(u, o, h)
  */
 int
 sifdefaultroute(u, l, g)
-    int unit;
+    int u;
     u_int32_t l, g;
 {
     struct rtentry rt;
@@ -1003,7 +1004,7 @@ sifdefaultroute(u, l, g)
  */
 int
 cifdefaultroute(u, l, g)
-    int unit;
+    int u;
     u_int32_t l, g;
 {
     struct rtentry rt;
@@ -1216,6 +1217,27 @@ GetMask(addr)
     return mask;
 }
 
+/*
+ * have_route_to - determine if the system has any route to
+ * a given IP address.
+ * For demand mode to work properly, we have to ignore routes
+ * through our own interface.
+ */
+int have_route_to(u_int32_t addr)
+{
+    return -1;
+}
+
+
+/*
+ * 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.