HPUX compatibility changes in getla()
authorEric Allman <eric@ucbvax.Berkeley.EDU>
Thu, 22 Apr 1993 03:52:24 +0000 (19:52 -0800)
committerEric Allman <eric@ucbvax.Berkeley.EDU>
Thu, 22 Apr 1993 03:52:24 +0000 (19:52 -0800)
SCCS-vsn: usr.sbin/sendmail/src/conf.c 6.46

usr/src/usr.sbin/sendmail/src/conf.c

index e4871bf..c1d8af2 100644 (file)
@@ -7,7 +7,7 @@
  */
 
 #ifndef lint
  */
 
 #ifndef lint
-static char sccsid[] = "@(#)conf.c     6.45 (Berkeley) %G%";
+static char sccsid[] = "@(#)conf.c     6.46 (Berkeley) %G%";
 #endif /* not lint */
 
 # include <sys/ioctl.h>
 #endif /* not lint */
 
 # include <sys/ioctl.h>
@@ -588,6 +588,7 @@ rlsesigs()
 #  endif
 #  if defined(hpux)
 #    define LA_TYPE            LA_FLOAT
 #  endif
 #  if defined(hpux)
 #    define LA_TYPE            LA_FLOAT
+#    define LA_AVENRUN         "avenrun"
 #  endif
 
 #  ifndef LA_TYPE
 #  endif
 
 #  ifndef LA_TYPE
@@ -683,6 +684,13 @@ getla()
                                        errstring(errno));
                        return (-1);
                }
                                        errstring(errno));
                        return (-1);
                }
+               if (Nl[X_AVENRUN].n_value == 0)
+               {
+                       if (tTd(3, 1))
+                               printf("getla: nlist(%s, %s) ==> 0\n",
+                                       _PATH_UNIX, LA_AVENRUN);
+                       return (-1);
+               }
        }
        if (tTd(3, 20))
                printf("getla: symbol address = %#x\n", Nl[X_AVENRUN].n_value);
        }
        if (tTd(3, 20))
                printf("getla: symbol address = %#x\n", Nl[X_AVENRUN].n_value);