home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Internet Tools 1993 July / Internet Tools.iso / RockRidge / mail / sendmail / sendmail-5.65c+IDA-1.4.4.1 / src / RCS / conf.c,v < prev    next >
Encoding:
Text File  |  1991-06-25  |  26.3 KB  |  1,624 lines

  1. head    5.26;
  2. branch    5.26.0;
  3. access;
  4. symbols
  5.     RELEASE:5.26.0.25
  6.     BETA:5.26.0.23
  7.     UICSO:5.26.0
  8.     VANILLA:5.26;
  9. locks; strict;
  10. comment    @ * @;
  11.  
  12.  
  13. 5.26
  14. date    90.06.20.08.35.28;    author paul;    state Exp;
  15. branches
  16.     5.26.0.1;
  17. next    ;
  18.  
  19. 5.26.0.1
  20. date    90.06.20.09.42.38;    author paul;    state Exp;
  21. branches;
  22. next    5.26.0.2;
  23.  
  24. 5.26.0.2
  25. date    90.06.25.09.20.32;    author paul;    state Exp;
  26. branches;
  27. next    5.26.0.3;
  28.  
  29. 5.26.0.3
  30. date    90.06.25.09.42.54;    author paul;    state Exp;
  31. branches;
  32. next    5.26.0.4;
  33.  
  34. 5.26.0.4
  35. date    90.06.25.14.26.17;    author paul;    state Exp;
  36. branches;
  37. next    5.26.0.5;
  38.  
  39. 5.26.0.5
  40. date    90.07.06.20.31.22;    author paul;    state Exp;
  41. branches;
  42. next    5.26.0.6;
  43.  
  44. 5.26.0.6
  45. date    90.10.16.08.14.45;    author paul;    state Exp;
  46. branches;
  47. next    5.26.0.7;
  48.  
  49. 5.26.0.7
  50. date    90.10.17.14.20.54;    author paul;    state Exp;
  51. branches;
  52. next    5.26.0.8;
  53.  
  54. 5.26.0.8
  55. date    90.11.01.23.46.37;    author paul;    state Exp;
  56. branches;
  57. next    5.26.0.9;
  58.  
  59. 5.26.0.9
  60. date    90.11.19.16.21.49;    author paul;    state Exp;
  61. branches;
  62. next    5.26.0.10;
  63.  
  64. 5.26.0.10
  65. date    90.11.24.02.37.57;    author paul;    state Exp;
  66. branches;
  67. next    5.26.0.11;
  68.  
  69. 5.26.0.11
  70. date    90.11.27.13.52.24;    author paul;    state Exp;
  71. branches;
  72. next    5.26.0.12;
  73.  
  74. 5.26.0.12
  75. date    90.11.28.14.17.32;    author paul;    state Exp;
  76. branches;
  77. next    5.26.0.13;
  78.  
  79. 5.26.0.13
  80. date    90.11.28.15.31.52;    author paul;    state Exp;
  81. branches;
  82. next    5.26.0.14;
  83.  
  84. 5.26.0.14
  85. date    90.11.29.21.15.23;    author paul;    state Exp;
  86. branches;
  87. next    5.26.0.15;
  88.  
  89. 5.26.0.15
  90. date    91.01.19.19.26.02;    author paul;    state Exp;
  91. branches;
  92. next    5.26.0.16;
  93.  
  94. 5.26.0.16
  95. date    91.03.04.21.48.23;    author paul;    state Exp;
  96. branches;
  97. next    5.26.0.17;
  98.  
  99. 5.26.0.17
  100. date    91.03.06.16.04.00;    author paul;    state Exp;
  101. branches;
  102. next    5.26.0.18;
  103.  
  104. 5.26.0.18
  105. date    91.03.25.23.03.14;    author paul;    state Exp;
  106. branches;
  107. next    5.26.0.19;
  108.  
  109. 5.26.0.19
  110. date    91.04.02.23.09.48;    author paul;    state Exp;
  111. branches;
  112. next    5.26.0.20;
  113.  
  114. 5.26.0.20
  115. date    91.04.05.14.55.15;    author paul;    state Exp;
  116. branches;
  117. next    5.26.0.21;
  118.  
  119. 5.26.0.21
  120. date    91.05.18.17.21.38;    author paul;    state Exp;
  121. branches;
  122. next    5.26.0.22;
  123.  
  124. 5.26.0.22
  125. date    91.05.22.02.30.43;    author paul;    state Exp;
  126. branches;
  127. next    5.26.0.23;
  128.  
  129. 5.26.0.23
  130. date    91.05.24.22.33.51;    author paul;    state Exp;
  131. branches;
  132. next    5.26.0.24;
  133.  
  134. 5.26.0.24
  135. date    91.06.05.17.16.21;    author paul;    state Exp;
  136. branches;
  137. next    5.26.0.25;
  138.  
  139. 5.26.0.25
  140. date    91.06.21.12.38.29;    author paul;    state Exp;
  141. branches;
  142. next    ;
  143.  
  144.  
  145. desc
  146. @@
  147.  
  148.  
  149. 5.26
  150. log
  151. @5.64 Berkeley release
  152. @
  153. text
  154. @/*
  155.  * Copyright (c) 1983 Eric P. Allman
  156.  * Copyright (c) 1988 Regents of the University of California.
  157.  * All rights reserved.
  158.  *
  159.  * Redistribution and use in source and binary forms are permitted provided
  160.  * that: (1) source distributions retain this entire copyright notice and
  161.  * comment, and (2) distributions including binaries display the following
  162.  * acknowledgement:  ``This product includes software developed by the
  163.  * University of California, Berkeley and its contributors'' in the
  164.  * documentation or other materials provided with the distribution and in
  165.  * all advertising materials mentioning features or use of this software.
  166.  * Neither the name of the University nor the names of its contributors may
  167.  * be used to endorse or promote products derived from this software without
  168.  * specific prior written permission.
  169.  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
  170.  * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
  171.  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  172.  */
  173.  
  174. #ifndef lint
  175. static char sccsid[] = "@@(#)conf.c    5.26 (Berkeley) 6/1/90";
  176. #endif /* not lint */
  177.  
  178. # include <sys/ioctl.h>
  179. # include <sys/param.h>
  180. # include <pwd.h>
  181. # include "sendmail.h"
  182. # include "pathnames.h"
  183.  
  184. /*
  185. **  CONF.C -- Sendmail Configuration Tables.
  186. **
  187. **    Defines the configuration of this installation.
  188. **
  189. **    Compilation Flags:
  190. **        VMUNIX -- running on a Berkeley UNIX system.
  191. **
  192. **    Configuration Variables:
  193. **        HdrInfo -- a table describing well-known header fields.
  194. **            Each entry has the field name and some flags,
  195. **            which are described in sendmail.h.
  196. **
  197. **    Notes:
  198. **        I have tried to put almost all the reasonable
  199. **        configuration information into the configuration
  200. **        file read at runtime.  My intent is that anything
  201. **        here is a function of the version of UNIX you
  202. **        are running, or is really static -- for example
  203. **        the headers are a superset of widely used
  204. **        protocols.  If you find yourself playing with
  205. **        this file too much, you may be making a mistake!
  206. */
  207.  
  208.  
  209.  
  210.  
  211. /*
  212. **  Header info table
  213. **    Final (null) entry contains the flags used for any other field.
  214. **
  215. **    Not all of these are actually handled specially by sendmail
  216. **    at this time.  They are included as placeholders, to let
  217. **    you know that "someday" I intend to have sendmail do
  218. **    something with them.
  219. */
  220.  
  221. struct hdrinfo    HdrInfo[] =
  222. {
  223.         /* originator fields, most to least significant  */
  224.     "resent-sender",    H_FROM|H_RESENT,
  225.     "resent-from",        H_FROM|H_RESENT,
  226.     "resent-reply-to",    H_FROM|H_RESENT,
  227.     "sender",        H_FROM,
  228.     "from",            H_FROM,
  229.     "reply-to",        H_FROM,
  230.     "full-name",        H_ACHECK,
  231.     "return-receipt-to",    H_FROM,
  232.     "errors-to",        H_FROM,
  233.         /* destination fields */
  234.     "to",            H_RCPT,
  235.     "resent-to",        H_RCPT|H_RESENT,
  236.     "cc",            H_RCPT,
  237.     "resent-cc",        H_RCPT|H_RESENT,
  238.     "bcc",            H_RCPT|H_ACHECK,
  239.     "resent-bcc",        H_RCPT|H_ACHECK|H_RESENT,
  240.         /* message identification and control */
  241.     "message-id",        0,
  242.     "resent-message-id",    H_RESENT,
  243.     "message",        H_EOH,
  244.     "text",            H_EOH,
  245.         /* date fields */
  246.     "date",            0,
  247.     "resent-date",        H_RESENT,
  248.         /* trace fields */
  249.     "received",        H_TRACE|H_FORCE,
  250.     "via",            H_TRACE|H_FORCE,
  251.     "mail-from",        H_TRACE|H_FORCE,
  252.  
  253.     NULL,            0,
  254. };
  255.  
  256.  
  257. /*
  258. **  ARPANET error message numbers.
  259. */
  260.  
  261. char    Arpa_Info[] =        "050";    /* arbitrary info */
  262. char    Arpa_TSyserr[] =    "451";    /* some (transient) system error */
  263. char    Arpa_PSyserr[] =    "554";    /* some (permanent) system error */
  264. char    Arpa_Usrerr[] =        "554";    /* some (fatal) user error */
  265.  
  266.  
  267.  
  268. /*
  269. **  Location of system files/databases/etc.
  270. */
  271.  
  272. char    *ConfFile =    _PATH_SENDMAILCF;    /* runtime configuration */
  273. char    *FreezeFile =    _PATH_SENDMAILFC;    /* frozen version of above */
  274.  
  275.  
  276.  
  277. /*
  278. **  Miscellaneous stuff.
  279. */
  280.  
  281. int    DtableSize =    50;        /* max open files; reset in 4.2bsd */
  282. extern int la;                /* load average */
  283. /*
  284. **  SETDEFAULTS -- set default values
  285. **
  286. **    Because of the way freezing is done, these must be initialized
  287. **    using direct code.
  288. **
  289. **    Parameters:
  290. **        none.
  291. **
  292. **    Returns:
  293. **        none.
  294. **
  295. **    Side Effects:
  296. **        Initializes a bunch of global variables to their
  297. **        default values.
  298. */
  299.  
  300. setdefaults()
  301. {
  302.     QueueLA = 8;
  303.     QueueFactor = 10000;
  304.     RefuseLA = 12;
  305.     SpaceSub = ' ';
  306.     WkRecipFact = 1000;
  307.     WkClassFact = 1800;
  308.     WkTimeFact = 9000;
  309.     FileMode = 0644;
  310.     DefUid = 1;
  311.     DefGid = 1;
  312.     setdefuser();
  313. }
  314.  
  315.  
  316. /*
  317. **  SETDEFUSER -- set/reset DefUser using DefUid (for initgroups())
  318. */
  319.  
  320. setdefuser()
  321. {
  322.     struct passwd *defpwent;
  323.  
  324.     if (DefUser != NULL)
  325.         free(DefUser);
  326.     if ((defpwent = getpwuid(DefUid)) != NULL)
  327.         DefUser = newstr(defpwent->pw_name);
  328.     else
  329.         DefUser = newstr("nobody");
  330. }
  331.  
  332.  
  333. /*
  334. **  GETRUID -- get real user id (V7)
  335. */
  336.  
  337. getruid()
  338. {
  339.     if (OpMode == MD_DAEMON)
  340.         return (RealUid);
  341.     else
  342.         return (getuid());
  343. }
  344.  
  345.  
  346. /*
  347. **  GETRGID -- get real group id (V7).
  348. */
  349.  
  350. getrgid()
  351. {
  352.     if (OpMode == MD_DAEMON)
  353.         return (RealGid);
  354.     else
  355.         return (getgid());
  356. }
  357.  
  358. /*
  359. **  USERNAME -- return the user id of the logged in user.
  360. **
  361. **    Parameters:
  362. **        none.
  363. **
  364. **    Returns:
  365. **        The login name of the logged in user.
  366. **
  367. **    Side Effects:
  368. **        none.
  369. **
  370. **    Notes:
  371. **        The return value is statically allocated.
  372. */
  373.  
  374. char *
  375. username()
  376. {
  377.     static char *myname = NULL;
  378.     extern char *getlogin();
  379.     register struct passwd *pw;
  380.     extern struct passwd *getpwuid();
  381.  
  382.     /* cache the result */
  383.     if (myname == NULL)
  384.     {
  385.         myname = getlogin();
  386.         if (myname == NULL || myname[0] == '\0')
  387.         {
  388.  
  389.             pw = getpwuid(getruid());
  390.             if (pw != NULL)
  391.                 myname = newstr(pw->pw_name);
  392.         }
  393.         else
  394.         {
  395.  
  396.             myname = newstr(myname);
  397.             if ((pw = getpwnam(myname)) == NULL ||
  398.                   getuid() != pw->pw_uid)
  399.             {
  400.                 pw = getpwuid(getuid());
  401.                 if (pw != NULL)
  402.                     myname = newstr(pw->pw_name);
  403.             }
  404.         }
  405.         if (myname == NULL || myname[0] == '\0')
  406.         {
  407.             syserr("Who are you?");
  408.             myname = "postmaster";
  409.         }
  410.     }
  411.  
  412.     return (myname);
  413. }
  414. /*
  415. **  TTYPATH -- Get the path of the user's tty
  416. **
  417. **    Returns the pathname of the user's tty.  Returns NULL if
  418. **    the user is not logged in or if s/he has write permission
  419. **    denied.
  420. **
  421. **    Parameters:
  422. **        none
  423. **
  424. **    Returns:
  425. **        pathname of the user's tty.
  426. **        NULL if not logged in or write permission denied.
  427. **
  428. **    Side Effects:
  429. **        none.
  430. **
  431. **    WARNING:
  432. **        Return value is in a local buffer.
  433. **
  434. **    Called By:
  435. **        savemail
  436. */
  437.  
  438. # include <sys/stat.h>
  439.  
  440. char *
  441. ttypath()
  442. {
  443.     struct stat stbuf;
  444.     register char *pathn;
  445.     extern char *ttyname();
  446.     extern char *getlogin();
  447.  
  448.     /* compute the pathname of the controlling tty */
  449.     if ((pathn = ttyname(2)) == NULL && (pathn = ttyname(1)) == NULL &&
  450.         (pathn = ttyname(0)) == NULL)
  451.     {
  452.         errno = 0;
  453.         return (NULL);
  454.     }
  455.  
  456.     /* see if we have write permission */
  457.     if (stat(pathn, &stbuf) < 0 || !bitset(02, stbuf.st_mode))
  458.     {
  459.         errno = 0;
  460.         return (NULL);
  461.     }
  462.  
  463.     /* see if the user is logged in */
  464.     if (getlogin() == NULL)
  465.         return (NULL);
  466.  
  467.     /* looks good */
  468.     return (pathn);
  469. }
  470. /*
  471. **  CHECKCOMPAT -- check for From and To person compatible.
  472. **
  473. **    This routine can be supplied on a per-installation basis
  474. **    to determine whether a person is allowed to send a message.
  475. **    This allows restriction of certain types of internet
  476. **    forwarding or registration of users.
  477. **
  478. **    If the hosts are found to be incompatible, an error
  479. **    message should be given using "usrerr" and FALSE should
  480. **    be returned.
  481. **
  482. **    'NoReturn' can be set to suppress the return-to-sender
  483. **    function; this should be done on huge messages.
  484. **
  485. **    Parameters:
  486. **        to -- the person being sent to.
  487. **
  488. **    Returns:
  489. **        TRUE -- ok to send.
  490. **        FALSE -- not ok.
  491. **
  492. **    Side Effects:
  493. **        none (unless you include the usrerr stuff)
  494. */
  495.  
  496. bool
  497. checkcompat(to)
  498.     register ADDRESS *to;
  499. {
  500. # ifdef lint
  501.     if (to == NULL)
  502.         to++;
  503. # endif lint
  504. # ifdef EXAMPLE_CODE
  505.     /* this code is intended as an example only */
  506.     register STAB *s;
  507.  
  508.     s = stab("arpa", ST_MAILER, ST_FIND);
  509.     if (s != NULL && CurEnv->e_from.q_mailer != LocalMailer &&
  510.         to->q_mailer == s->s_mailer)
  511.     {
  512.         usrerr("No ARPA mail through this machine: see your system administration");
  513.         /* NoReturn = TRUE; to supress return copy */
  514.         return (FALSE);
  515.     }
  516. # endif EXAMPLE_CODE
  517.     return (TRUE);
  518. }
  519. /*
  520. **  HOLDSIGS -- arrange to hold all signals
  521. **
  522. **    Parameters:
  523. **        none.
  524. **
  525. **    Returns:
  526. **        none.
  527. **
  528. **    Side Effects:
  529. **        Arranges that signals are held.
  530. */
  531.  
  532. holdsigs()
  533. {
  534. }
  535. /*
  536. **  RLSESIGS -- arrange to release all signals
  537. **
  538. **    This undoes the effect of holdsigs.
  539. **
  540. **    Parameters:
  541. **        none.
  542. **
  543. **    Returns:
  544. **        none.
  545. **
  546. **    Side Effects:
  547. **        Arranges that signals are released.
  548. */
  549.  
  550. rlsesigs()
  551. {
  552. }
  553. /*
  554. **  GETLA -- get the current load average
  555. **
  556. **    This code stolen from la.c.
  557. **
  558. **    Parameters:
  559. **        none.
  560. **
  561. **    Returns:
  562. **        The current load average as an integer.
  563. **
  564. **    Side Effects:
  565. **        none.
  566. */
  567.  
  568. #ifndef sun
  569.  
  570. getla()
  571. {
  572.     double avenrun[3];
  573.  
  574.     if (getloadavg(avenrun, sizeof(avenrun) / sizeof(avenrun[0])) < 0)
  575.         return (0);
  576.     return ((int) (avenrun[0] + 0.5));
  577. }
  578.  
  579. #else /* sun */
  580.  
  581. #include <nlist.h>
  582.  
  583. struct    nlist Nl[] =
  584. {
  585.     { "_avenrun" },
  586. #define    X_AVENRUN    0
  587.     { 0 },
  588. };
  589.  
  590.  
  591. extern int la;
  592.  
  593. getla()
  594. {
  595.     static int kmem = -1;
  596.     long avenrun[3];
  597.     extern off_t lseek();
  598.  
  599.     if (kmem < 0)
  600.     {
  601.         kmem = open("/dev/kmem", 0, 0);
  602.         if (kmem < 0)
  603.             return (-1);
  604.         (void) ioctl(kmem, (int) FIOCLEX, (char *) 0);
  605.         nlist("/vmunix", Nl);
  606.         if (Nl[0].n_type == 0)
  607.             return (-1);
  608.     }
  609.     if (lseek(kmem, (off_t) Nl[X_AVENRUN].n_value, 0) == -1 ||
  610.         read(kmem, (char *) avenrun, sizeof(avenrun)) < sizeof(avenrun))
  611.     {
  612.         /* thank you Ian */
  613.         return (-1);
  614.     }
  615.     return ((int) (avenrun[0] + FSCALE/2) >> FSHIFT);
  616. }
  617.  
  618. #endif /* sun */
  619. /*
  620. **  SHOULDQUEUE -- should this message be queued or sent?
  621. **
  622. **    Compares the message cost to the load average to decide.
  623. **
  624. **    Parameters:
  625. **        pri -- the priority of the message in question.
  626. **
  627. **    Returns:
  628. **        TRUE -- if this message should be queued up for the
  629. **            time being.
  630. **        FALSE -- if the load is low enough to send this message.
  631. **
  632. **    Side Effects:
  633. **        none.
  634. */
  635.  
  636. bool
  637. shouldqueue(pri)
  638.     long pri;
  639. {
  640.     if (la < QueueLA)
  641.         return (FALSE);
  642.     return (pri > (QueueFactor / (la - QueueLA + 1)));
  643. }
  644. /*
  645. **  SETPROCTITLE -- set process title for ps
  646. **
  647. **    Parameters:
  648. **        fmt -- a printf style format string.
  649. **        a, b, c -- possible parameters to fmt.
  650. **
  651. **    Returns:
  652. **        none.
  653. **
  654. **    Side Effects:
  655. **        Clobbers argv of our main procedure so ps(1) will
  656. **        display the title.
  657. */
  658.  
  659. /*VARARGS1*/
  660. setproctitle(fmt, a, b, c)
  661.     char *fmt;
  662. {
  663. # ifdef SETPROCTITLE
  664.     register char *p;
  665.     register int i;
  666.     extern char **Argv;
  667.     extern char *LastArgv;
  668.     char buf[MAXLINE];
  669.  
  670.     (void) sprintf(buf, fmt, a, b, c);
  671.  
  672.     /* make ps print "(sendmail)" */
  673.     p = Argv[0];
  674.     *p++ = '-';
  675.  
  676.     i = strlen(buf);
  677.     if (i > LastArgv - p - 2)
  678.     {
  679.         i = LastArgv - p - 2;
  680.         buf[i] = '\0';
  681.     }
  682.     (void) strcpy(p, buf);
  683.     p += i;
  684.     while (p < LastArgv)
  685.         *p++ = ' ';
  686. # endif SETPROCTITLE
  687. }
  688. /*
  689. **  REAPCHILD -- pick up the body of my child, lest it become a zombie
  690. **
  691. **    Parameters:
  692. **        none.
  693. **
  694. **    Returns:
  695. **        none.
  696. **
  697. **    Side Effects:
  698. **        Picks up extant zombies.
  699. */
  700.  
  701. # ifdef VMUNIX
  702. # include <sys/wait.h>
  703. # endif VMUNIX
  704.  
  705. reapchild()
  706. {
  707. # ifdef WNOHANG
  708.     union wait status;
  709.  
  710.     while (wait3(&status, WNOHANG, (struct rusage *) NULL) > 0)
  711.         continue;
  712. # else WNOHANG
  713.     auto int status;
  714.  
  715.     while (wait(&status) > 0)
  716.         continue;
  717. # endif WNOHANG
  718. }
  719. @
  720.  
  721.  
  722. 5.26.0.1
  723. log
  724. @IDA patches
  725. @
  726. text
  727. @a86 1
  728.     "apparently-to",    H_RCPT,
  729. a120 3
  730. #ifdef OUTPUT_PID
  731. char    *PidFile =    _PATH_SENDMAILPID;    /* sendmail daemon PID */
  732. #endif /* OUTPUT_PID */
  733. a148 2
  734.     int c;
  735.  
  736. a159 5
  737.  
  738. # if defined(NDBM) || defined(SDBM)
  739.     for (c = 0; c < 128; c++)
  740.         DbmTab[c].db_dbm = DB_NOTYETOPEN;
  741. # endif /* !NDBM && !SDBM */
  742. d163 1
  743. a163 1
  744.   /*
  745. d350 1
  746. a350 1
  747. # endif /* lint */
  748. d363 1
  749. a363 1
  750. # endif /* EXAMPLE_CODE */
  751. d437 3
  752. a441 3
  753. # ifdef sequent
  754.     return (1);
  755. # else /* !sequent */
  756. a462 2
  757.     /* return ((int) (avenrun[0] + 0.5)); */
  758. # endif /* sequent */
  759. d533 1
  760. a533 1
  761. # endif /* SETPROCTITLE */
  762. d550 1
  763. a550 1
  764. # endif /* VMUNIX */
  765. d559 1
  766. a559 1
  767. # else /* !WNOHANG */
  768. d564 1
  769. a564 1
  770. # endif /* WNOHANG */
  771. @
  772.  
  773.  
  774. 5.26.0.2
  775. log
  776. @Patches for HP-UX from Andy Linton <root@@comp.vuw.ac.nz>.  Thanks Andy!
  777. @
  778. text
  779. @a26 3
  780. # if defined(hpux)
  781. # include <sgtty.h>
  782. # endif /* hpux */
  783. d131 2
  784. a132 6
  785. #ifdef hpux
  786. #include <stdio.h>
  787. int             DtableSize = _NFILE;    /* max open files */
  788. #else
  789. int             DtableSize = 50;/* max open files; reset in 4.2bsd */
  790. #endif
  791. d426 1
  792. a426 1
  793. #if !defined(sun) && !defined (hpux)
  794. d437 1
  795. a437 1
  796. #else /* sun  || hpux */
  797. d443 1
  798. a443 5
  799. #ifdef hp9000s800
  800.     {"avenrun"},
  801. #else
  802.     {"_avenrun"},
  803. #endif hp9000s800
  804. a453 3
  805. # if defined(hpux)
  806.     double avenrun[3];
  807. # else
  808. a454 1
  809. # endif /* hpux */
  810. d463 1
  811. a463 5
  812. #if defined(hpux)
  813.         (void) nlist ("/hp-ux", Nl);
  814. #else
  815.         (void) nlist ("/vmunix", Nl);
  816. #endif /* hpux */
  817. a464 7
  818.         {
  819.             /*
  820.              * if nlist() has failed we can't use Nl to grope 
  821.              * about in kmem on subsequent calls to getla()
  822.              */
  823.               close (kmem);
  824.             kmem = -1;
  825. a465 1
  826.         }
  827. a472 3
  828. # if defined(hpux)
  829.     return ((int) (avenrun[0] + 0.5));
  830. # else
  831. d474 1
  832. a474 1
  833. # endif /* hpux */
  834. @
  835.  
  836.  
  837. 5.26.0.3
  838. log
  839. @Inserted _PATH_UNIX and _PATH_KMEM instead of "/vmunix" and "/dev/kmem".
  840. @
  841. text
  842. @d474 1
  843. a474 1
  844.         kmem = open(_PATH_KMEM, 0, 0);
  845. d478 5
  846. a482 1
  847.         (void) nlist (_PATH_UNIX, Nl);
  848. @
  849.  
  850.  
  851. 5.26.0.4
  852. log
  853. @Encore specifics from Neil Rickert.
  854. @
  855. text
  856. @d21 1
  857. a21 1
  858. # ifndef lint
  859. d23 1
  860. a23 1
  861. # endif /* not lint */
  862. d28 1
  863. a28 1
  864. #  include <sgtty.h>
  865. d125 1
  866. a125 1
  867. # ifdef OUTPUT_PID
  868. d127 1
  869. a127 1
  870. # endif /* OUTPUT_PID */
  871. d134 2
  872. a135 2
  873. # ifdef hpux
  874. #  include <stdio.h>
  875. d137 1
  876. a137 1
  877. # else /* ! hpux */
  878. d139 1
  879. a139 1
  880. # endif /* hpux */
  881. d177 1
  882. a177 1
  883. # endif /* NDBM || SDBM */
  884. d433 1
  885. a433 1
  886. # if !defined(UMAX)
  887. a434 2
  888. #  if !defined(sun) && !defined (hpux)
  889.  
  890. d444 1
  891. a444 1
  892. #  else /* sun  || hpux */
  893. d446 1
  894. a446 1
  895. #   include <nlist.h>
  896. d450 1
  897. a450 1
  898. #   ifdef hp9000s800
  899. d452 1
  900. a452 1
  901. #   else /* !hp9000s800 */
  902. d454 2
  903. a455 2
  904. #   endif /* hp9000s800 */
  905. #   define    X_AVENRUN    0
  906. d461 1
  907. a461 1
  908. #   ifdef sequent
  909. d463 1
  910. a463 1
  911. #   else /* !sequent */
  912. d465 1
  913. a465 1
  914. #    if defined(hpux)
  915. d467 1
  916. a467 1
  917. #    else /* !hpux */
  918. d469 1
  919. a469 1
  920. #    endif /* hpux */
  921. d496 1
  922. a496 1
  923. #    if defined(hpux)
  924. d498 1
  925. a498 1
  926. #    else /* !hpux */
  927. d500 2
  928. a501 2
  929. #    endif /* hpux */
  930. #   endif /* sequent */
  931. d504 1
  932. a504 11
  933. #  endif /* !sun && !hpux */
  934.  
  935. # else /* !UMAX */
  936. getla()
  937. {
  938.     double avenrun[3];
  939.     
  940.     get_stats(avenrun,(double*)0,(char *)0);
  941.     return ((int) (avenrun[0] + 0.5));
  942. }
  943. # endif /* UMAX */
  944. d588 1
  945. a588 1
  946. #  include <sys/wait.h>
  947. @
  948.  
  949.  
  950. 5.26.0.5
  951. log
  952. @Redid the getla code to eliminate nested defines.  #elseif would sure be
  953. nice.  
  954. @
  955. text
  956. @d433 1
  957. a433 3
  958. /*
  959.  * The old-fashioned, time-honored, go grubbing into the kernel method.
  960.  */
  961. d435 1
  962. a435 2
  963. #if defined(sun) || defined(hpux)
  964. # include <nlist.h>
  965. d437 13
  966. d452 1
  967. a452 1
  968. # if defined(hp9000s800)
  969. d454 1
  970. a454 1
  971. # else /* !hp9000s800 */
  972. d456 2
  973. a457 2
  974. # endif /* hp9000s800 */
  975. # define    X_AVENRUN    0
  976. d463 3
  977. d467 1
  978. a467 1
  979. # if defined(hpux)
  980. d469 1
  981. a469 1
  982. # else /* !hpux */
  983. d471 1
  984. a471 1
  985. # endif /* hpux */
  986. d498 1
  987. a498 1
  988. # if defined(hpux)
  989. d500 1
  990. a500 1
  991. # else /* !hpux */
  992. d502 2
  993. a503 1
  994. # endif /* hpux */
  995. d506 1
  996. a506 1
  997. #endif /* sun || hpux */
  998. d508 1
  999. a508 12
  1000. /*
  1001.  * The "it's too hard to do right" way, so punt it.
  1002.  */
  1003.  
  1004. #if defined(sequent)
  1005.    getla() { return(1); }    /* Fake it */
  1006. #endif /* sequent */
  1007.  
  1008. /*
  1009.  * Special ways for machines off the beaten path
  1010.  */
  1011. #if defined(UMAX)
  1012. d516 1
  1013. a516 15
  1014. #endif /* UMAX */
  1015.  
  1016. /*
  1017.  * Everybody else? Ha!
  1018.  */
  1019. #if !defined(sun) && !defined(hpux) && !defined(sequent) && !defined(UMAX)
  1020. getla()
  1021. {
  1022.     double avenrun[3];
  1023.  
  1024.     if (getloadavg(avenrun, sizeof(avenrun) / sizeof(avenrun[0])) < 0)
  1025.         return (0);
  1026.     return ((int) (avenrun[0] + 0.5));
  1027. }
  1028. #endif /* !sun && !hpux && !sequent && !UMAX */
  1029. @
  1030.  
  1031.  
  1032. 5.26.0.6
  1033. log
  1034. @Re-did #statement indentation.  Added support for GDBM & MDBM.  Rolled in
  1035. getloadavg.c and deleted Makefile entry.  Changed Encore flag UMAX to
  1036. MMAX to avoid collision with #define used on Integrated Solutions boxes.
  1037. Bruce Lilly (bruce%balilly@@sonyd1.broadcast.sony.com) provided unixpc and
  1038. some bug fixes.  His varargs code was changed to work with the VSPRINTF
  1039. #define in conf.h.
  1040. @
  1041. text
  1042. @d21 1
  1043. a21 1
  1044. #ifndef lint
  1045. d23 1
  1046. a23 1
  1047. #endif /* not lint */
  1048. d25 8
  1049. a32 12
  1050. #include <sys/ioctl.h>
  1051. #include <sys/param.h>
  1052. #include <sys/types.h>
  1053. #if defined(hpux)
  1054. # include <sgtty.h>
  1055. #endif /* hpux */
  1056. #include <pwd.h>
  1057. #include "sendmail.h"
  1058. #include "pathnames.h"
  1059. #if defined(__convex__) && defined(SHARE)
  1060. # include <shares.h>
  1061. #endif /* __convex__ && SHARE */
  1062. d172 1
  1063. d174 1
  1064. a174 1
  1065. # if defined(NDBM) || defined(OTHERDBM)
  1066. d177 1
  1067. a177 1
  1068. # endif /* NDBM || OTHERDBM */
  1069. d181 1
  1070. a181 1
  1071. /*
  1072. d223 1
  1073. a223 1
  1074. /*
  1075. d266 1
  1076. a266 3
  1077.                 if (pw != NULL) {
  1078.                     if (myname)
  1079.                         free(myname);
  1080. a267 1
  1081.                 }
  1082. d437 1
  1083. a437 1
  1084. #if defined(sun) || defined(hpux) || defined(unixpc)
  1085. a450 4
  1086. #ifdef unixpc
  1087. extern    int    la;
  1088. #endif /* unixpc */
  1089.  
  1090. d454 1
  1091. a454 1
  1092. # if defined(hpux) || defined(unixpc)
  1093. d456 1
  1094. a456 1
  1095. # else /* !hpux && !unixpc */
  1096. d458 1
  1097. a458 1
  1098. # endif /* hpux || unixpc */
  1099. d485 1
  1100. a485 1
  1101. # if defined(hpux) || defined(unixpc)
  1102. d487 1
  1103. a487 1
  1104. # else /* !hpux && !unixpc */
  1105. d489 1
  1106. a489 1
  1107. # endif /* hpux || unixpc */
  1108. d492 1
  1109. a492 1
  1110. #endif /* sun || hpux || unixpc */
  1111. d498 1
  1112. a498 1
  1113. #if defined(sequent) || defined(IRIS)
  1114. d500 1
  1115. a500 1
  1116. #endif /* sequent || IRIS */
  1117. d505 1
  1118. a505 1
  1119. #if defined(MMAX)
  1120. d513 1
  1121. a513 1
  1122. #endif /* MMAX */
  1123. d518 1
  1124. a518 2
  1125. #if !defined(sun) && !defined(hpux) && !defined(unixpc) && \
  1126.     !defined(sequent) && !defined(IRIS) && !defined(MMAX)
  1127. d527 1
  1128. a527 33
  1129.  
  1130. #include <nlist.h>
  1131.  
  1132. struct    nlist Nl[] =
  1133. {
  1134.     { "_avenrun" },
  1135. #define    X_AVENRUN    0
  1136.     { 0 },
  1137. };
  1138.  
  1139. /* ARGSUSED */
  1140. getloadavg(avenrun, n)
  1141.     double *avenrun;
  1142.     int n;
  1143. {
  1144.     static int kmem = -1;
  1145.     extern off_t lseek();
  1146.  
  1147.     if (kmem < 0) {
  1148.         kmem = open(_PATH_KMEM, 0, 0);
  1149.         if (kmem < 0)
  1150.             return (-1);
  1151.         (void) ioctl(kmem, (int) FIOCLEX, (char *) 0);
  1152.         nlist(_PATH_UNIX, Nl);
  1153.         if (Nl[0].n_type == 0)
  1154.             return (-1);
  1155.     }
  1156.     if (lseek(kmem, (off_t) Nl[X_AVENRUN].n_value, 0) == -1 ||
  1157.         read(kmem, (char *) avenrun, sizeof(avenrun)) < sizeof(avenrun))
  1158.         return (-1);
  1159.     return (0);
  1160. }
  1161. #endif /* !sun && !hpux && && !unixpc && !sequent && !IRIS && !MMAX */
  1162. a568 7
  1163. # ifdef VSPRINTF
  1164. setproctitle(va_alist)
  1165. va_dcl
  1166. {
  1167.     va_list    ap;
  1168.     register char *fmt;
  1169. # else /* !VSPRINTF */
  1170. a571 1
  1171. # endif /* VSPRINTF */
  1172. a578 6
  1173. #  ifdef VSPRINTF
  1174.     va_start(ap);
  1175.     fmt = va_arg(ap, char *);
  1176.     (void) vsprintf(buf, fmt, ap);
  1177.     va_end(ap);
  1178. #  else /* !VSPRINTF */
  1179. a579 1
  1180. #  endif /* VSPRINTF */
  1181. a626 4
  1182. #ifdef SIGCLD
  1183.     /* reset handler */
  1184.     (void) signal(SIGCLD, reapchild);
  1185. #endif /* SIGCLD */
  1186. @
  1187.  
  1188.  
  1189. 5.26.0.7
  1190. log
  1191. @Check whether FIOCLEX is defined before kernel diving, fake load average
  1192. otherwise.
  1193. @
  1194. text
  1195. @d508 1
  1196. a508 1
  1197. #if defined(sequent) || !defined(FIOCLEX)
  1198. d510 1
  1199. a510 1
  1200. #endif /* sequent || !FIOCLEX */
  1201. d528 1
  1202. a528 1
  1203. #if defined(FIOCLEX) && !defined(sun) && !defined(hpux) && !defined(unixpc) && \
  1204. @
  1205.  
  1206.  
  1207. 5.26.0.8
  1208. log
  1209. @Protect against X400 loops.  Provided by Francis Dupont (dupont@@inria.inria.fr)
  1210. @
  1211. text
  1212. @a106 1
  1213.     "x400-received",    H_TRACE,
  1214. @
  1215.  
  1216.  
  1217. 5.26.0.9
  1218. log
  1219. @Gutted out load average code.  Replaced in the getloadavg.c file from
  1220. the X11R3 distribution.
  1221. @
  1222. text
  1223. @d28 3
  1224. d139 6
  1225. d428 1
  1226. a428 1
  1227. **    Calls getloadavg() which is derived from the X11R4 'xload' utility.
  1228. d440 22
  1229. d464 7
  1230. a470 1
  1231.         double avenrun;
  1232. d472 29
  1233. a500 3
  1234.         if (getloadavg(&avenrun) < 0)
  1235.                 return (0);
  1236.         return ((int) (avenrun + 0.5));
  1237. d502 70
  1238. @
  1239.  
  1240.  
  1241. 5.26.0.10
  1242. log
  1243. @Deleted extern declaration of getpwuid().
  1244. @
  1245. text
  1246. @d240 1
  1247. @
  1248.  
  1249.  
  1250. 5.26.0.11
  1251. log
  1252. @Print the loadaverage for -d3.1.
  1253. @
  1254. text
  1255. @a435 4
  1256.  
  1257.     /* same test used in main.c */
  1258.     if (tTd(3, 1))
  1259.         printf("Load average: %3.1f\n", avenrun);
  1260. @
  1261.  
  1262.  
  1263. 5.26.0.12
  1264. log
  1265. @Freeze/thaw code now included only if _PATH_SENDMAILFC is #define'd in
  1266. pathnames.h .
  1267. @
  1268. text
  1269. @a125 1
  1270. #ifdef _PATH_SENDMAILFC
  1271. a126 1
  1272. #endif /* _PATH_SENDMAILFC */
  1273. @
  1274.  
  1275.  
  1276. 5.26.0.13
  1277. log
  1278. @Declare reapchild() to be SIG_TYPE.
  1279. @
  1280. text
  1281. @a544 1
  1282. SIG_TYPE
  1283. @
  1284.  
  1285.  
  1286. 5.26.0.14
  1287. log
  1288. @Deleted #ifdef/#define OUTPUT_PID in favor of testing whether _PATH_SENDMAILPID
  1289. is set.  sendmail.h now #include's pathnames.h instead of the other
  1290. modules.
  1291. @
  1292. text
  1293. @d30 1
  1294. a125 1
  1295.  
  1296. d129 1
  1297. a129 2
  1298.  
  1299. #ifdef _PATH_SENDMAILPID
  1300. d131 1
  1301. a131 1
  1302. #endif /* _PATH_SENDMAILPID */
  1303. @
  1304.  
  1305.  
  1306. 5.26.0.15
  1307. log
  1308. @Deleted #include <sys/types.h> as it's already included via sendmail.h from
  1309. useful.h.  #include "sendmail.h" relocated to top of #include list.
  1310. @
  1311. text
  1312. @a24 1
  1313. #include "sendmail.h"
  1314. d27 1
  1315. d29 1
  1316. @
  1317.  
  1318.  
  1319. 5.26.0.16
  1320. log
  1321. @ANSIfied.
  1322. @
  1323. text
  1324. @a32 2
  1325. extern char *ttyname(), *getlogin();;
  1326.  
  1327. d58 2
  1328. a155 1
  1329. void
  1330. a181 1
  1331. void
  1332. d240 1
  1333. d309 2
  1334. a395 1
  1335. void
  1336. a413 1
  1337. void
  1338. d436 1
  1339. a436 1
  1340.         if (getloadavg((caddr_t) &avenrun) < 0)
  1341. a484 1
  1342. void
  1343. d486 1
  1344. a486 2
  1345. setproctitle(fmt, va_alist)
  1346.     const char *fmt;
  1347. d490 1
  1348. d493 1
  1349. a493 1
  1350.     const char *fmt;
  1351. d505 1
  1352. d545 1
  1353. a545 1
  1354. void
  1355. a547 1
  1356.     int pid;
  1357. d551 1
  1358. a551 4
  1359.     while ((pid = wait3(&status, WNOHANG, (struct rusage *) NULL)) > 0)
  1360.     {
  1361.         if (tTd(4, 2))
  1362.             printf("reapchild: wait3 (pid = %d)\n", pid);
  1363. a552 1
  1364.     }
  1365. d556 1
  1366. a556 4
  1367.     while ((pid = wait(&status)) > 0)
  1368.     {
  1369.         if (tTd(4, 2))
  1370.             printf("reapchild: wait (pid = %d)\n", pid);
  1371. a557 1
  1372.     }
  1373. @
  1374.  
  1375.  
  1376. 5.26.0.17
  1377. log
  1378. @Changed reset of SIGCLD to SIGCHLD instead.  If SIGCHLD is not defined by
  1379. the system, then useful.h will equate it to SIGCLD in the SYSV universe.
  1380. It does no harm on systems that reset signals automatically.
  1381. @
  1382. text
  1383. @d172 1
  1384. a172 1
  1385. #if defined(NDBM) || defined(OTHERDBM)
  1386. d175 1
  1387. a175 1
  1388. #endif /* NDBM || OTHERDBM */
  1389. d303 1
  1390. a303 1
  1391. #include <sys/stat.h>
  1392. d363 1
  1393. a363 1
  1394. #ifdef lint
  1395. d366 2
  1396. a367 2
  1397. #endif /* lint */
  1398. #ifdef EXAMPLE_CODE
  1399. d379 1
  1400. a379 1
  1401. #endif /* EXAMPLE_CODE */
  1402. d487 1
  1403. a487 1
  1404. #ifdef VSPRINTF
  1405. d493 1
  1406. a493 1
  1407. #else /* !VSPRINTF */
  1408. d497 2
  1409. a498 2
  1410. #endif /* VSPRINTF */
  1411. #ifdef SETPROCTITLE
  1412. d505 1
  1413. a505 1
  1414. # ifdef VSPRINTF
  1415. d509 1
  1416. a509 1
  1417. # else /* !VSPRINTF */
  1418. d511 1
  1419. a511 1
  1420. # endif /* VSPRINTF */
  1421. d527 1
  1422. a527 1
  1423. #endif /* SETPROCTITLE */
  1424. d542 3
  1425. a544 3
  1426. #ifdef VMUNIX
  1427. # include <sys/wait.h>
  1428. #endif /* VMUNIX */
  1429. d550 1
  1430. a550 1
  1431. #ifdef WNOHANG
  1432. d559 1
  1433. a559 1
  1434. #else /* !WNOHANG */
  1435. d568 5
  1436. a572 5
  1437. #endif /* WNOHANG */
  1438. #ifdef SIGCHLD
  1439.     /* reset handler (required for SYSV when SIGCLD == SIGCHLD ???) XXX */
  1440.     (void) signal(SIGCHLD, reapchild);
  1441. #endif /* SIGCHLD */
  1442. @
  1443.  
  1444.  
  1445. 5.26.0.18
  1446. log
  1447. @setproctitle() only works in non-SYSV environments.
  1448. @
  1449. text
  1450. @d263 1
  1451. a263 2
  1452.                 if (pw != NULL)
  1453.                 {
  1454. d498 1
  1455. a498 1
  1456. #if defined(SETPROCTITLE) && !defined(SYSV)
  1457. d527 1
  1458. a527 1
  1459. #endif /* SETPROCTITLE && !SYSV */
  1460. @
  1461.  
  1462.  
  1463. 5.26.0.19
  1464. log
  1465. @Use stdarg instead of varargs when __STDC__ && VSPRINTF are true.
  1466. @
  1467. text
  1468. @a438 3
  1469.     {
  1470.         if (tTd(3, 1))
  1471.             printf("Load average: getloadavg() returned -1\n");
  1472. a439 1
  1473.     }
  1474. a488 3
  1475. # ifdef __STDC__
  1476. setproctitle(const char *fmt, ...)
  1477. # else /* !__STDC__ */
  1478. a491 1
  1479. # endif /* __STDC__ */
  1480. d493 1
  1481. a493 1
  1482.     va_list    args;
  1483. d507 3
  1484. a509 7
  1485. #  ifdef __STDC__
  1486.     va_start(args, fmt);
  1487. #  else /* !__STDC__ */
  1488.     va_start(args);
  1489. #  endif /* __STDC__ */
  1490.     (void) vsprintf(buf, fmt, args);
  1491.     va_end(args);
  1492. d547 1
  1493. a547 1
  1494. SIG_TYPE
  1495. @
  1496.  
  1497.  
  1498. 5.26.0.20
  1499. log
  1500. @Added RCS ID string
  1501. @
  1502. text
  1503. @a22 1
  1504. static char rcsid[] = "@@(#)$Id$";
  1505. @
  1506.  
  1507.  
  1508. 5.26.0.21
  1509. log
  1510. @System 5 and general improvement patches contributed by Bruce Lilly
  1511. (bruce%balilly@@broadcast.sony.com).
  1512. @
  1513. text
  1514. @d22 2
  1515. a23 2
  1516. static char sccsid[] = "@@(#)conf.c    5.26 (Berkeley) 6/1/90    %I% local";
  1517. static char rcsid[] = "@@(#)$Id: conf.c,v 5.26.0.20 1991/04/05 14:55:15 paul Exp paul $";
  1518. a201 1
  1519. int
  1520. a214 1
  1521. int
  1522. a434 1
  1523. int
  1524. @
  1525.  
  1526.  
  1527. 5.26.0.22
  1528. log
  1529. @Eliminated non-#define VSPRINT as a portable vsprintf() is now included
  1530. in vprintf.c.
  1531. @
  1532. text
  1533. @d23 1
  1534. a23 1
  1535. static char rcsid[] = "@@(#)$Id: conf.c,v 5.26.0.21 1991/05/18 17:21:38 paul Exp paul $";
  1536. d496 2
  1537. a497 1
  1538. #ifdef __STDC__
  1539. d499 1
  1540. a499 1
  1541. #else /* !__STDC__ */
  1542. d503 1
  1543. a503 1
  1544. #endif /* __STDC__ */
  1545. d506 5
  1546. d518 2
  1547. a519 1
  1548. # ifdef __STDC__
  1549. d521 1
  1550. a521 1
  1551. # else /* !__STDC__ */
  1552. d523 1
  1553. a523 1
  1554. # endif /* __STDC__ */
  1555. d526 3
  1556. @
  1557.  
  1558.  
  1559. 5.26.0.23
  1560. log
  1561. @Rationalized reapchild() based on whether LACK_WAIT3 is defined.
  1562. @
  1563. text
  1564. @d23 1
  1565. a23 1
  1566. static char rcsid[] = "@@(#)$Id: conf.c,v 5.26.0.23 1991/05/23 21:20:19 paul Exp paul $";
  1567. d557 1
  1568. a557 10
  1569. #ifdef LACK_WAIT3
  1570.     int status;
  1571.  
  1572.     if ((pid = wait(&status)) > 0)
  1573.         if (tTd(4, 2))
  1574.             printf("reapchild: wait (pid = %d)\n", pid);
  1575.  
  1576.     /* reset handler */
  1577.     (void) signal(SIGCHLD, reapchild);
  1578. #else /* !LACK_WAIT3 */
  1579. d566 14
  1580. a579 1
  1581. #endif /* LACK_WAIT3 */
  1582. @
  1583.  
  1584.  
  1585. 5.26.0.24
  1586. log
  1587. @Changed an occurence of ';;' to ';'
  1588. @
  1589. text
  1590. @d23 1
  1591. a23 1
  1592. static char rcsid[] = "@@(#)$Id: conf.c,v 5.26.0.23 1991/05/24 22:33:51 paul Exp paul $";
  1593. d34 1
  1594. a34 1
  1595. extern char *ttyname(), *getlogin();
  1596. @
  1597.  
  1598.  
  1599. 5.26.0.25
  1600. log
  1601. @Added additional ANSI C changes.
  1602. @
  1603. text
  1604. @d22 2
  1605. a23 2
  1606. static char sccsid[] = "@@(#)conf.c    5.26 (Berkeley) 6/1/90";
  1607. static char rcsid[] = "@@(#)$Id: conf.c,v 5.26.0.24 1991/06/05 17:16:21 paul Exp paul $";
  1608. a33 3
  1609. #ifdef __STDC__
  1610. extern char *ttyname(int), *getlogin(void);
  1611. #else /* !__STDC__ */
  1612. a34 1
  1613. #endif /* __STDC__ */
  1614. d504 1
  1615. a505 1
  1616.     va_list    args;
  1617. a575 5
  1618. #ifdef notdef
  1619. #if ( SIG_TYPE == int )
  1620.     return 0;
  1621. #endif /* SIG_TYPE == int */
  1622. #endif /* notdef */
  1623. @
  1624.