TRY_VERSIONED_CF_NAME is a botch -- consider mailstats
authorEric Allman <eric@ucbvax.Berkeley.EDU>
Sun, 11 Jun 1995 03:15:22 +0000 (19:15 -0800)
committerEric Allman <eric@ucbvax.Berkeley.EDU>
Sun, 11 Jun 1995 03:15:22 +0000 (19:15 -0800)
SCCS-vsn: usr.sbin/sendmail/src/conf.c 8.192

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

index 542bc5f..ef0ed46 100644 (file)
@@ -7,7 +7,7 @@
  */
 
 #ifndef lint
  */
 
 #ifndef lint
-static char sccsid[] = "@(#)conf.c     8.191 (Berkeley) %G%";
+static char sccsid[] = "@(#)conf.c     8.192 (Berkeley) %G%";
 #endif /* not lint */
 
 # include "sendmail.h"
 #endif /* not lint */
 
 # include "sendmail.h"
@@ -2841,10 +2841,6 @@ resetlimits()
 char *
 getcfname()
 {
 char *
 getcfname()
 {
-#ifdef TRY_VERSIONED_CF_NAME
-       int i;
-       static char cbuf[200];
-#endif
 
        if (ConfFile != NULL)
                return ConfFile;
 
        if (ConfFile != NULL)
                return ConfFile;
@@ -2860,42 +2856,6 @@ getcfname()
        }
 #endif
 
        }
 #endif
 
-#ifdef TRY_VERSIONED_CF_NAME
-       /*
-       **  Try sendmail.8.6.12.cf, then sendmail.8.6.cf, then
-       **  sendmail.8.cf, and finally sendmail.cf.
-       **
-       **      I suppose it should really try a search path here --
-       **      e.g., /etc/sendmail.cf, /etc/mail/sendmail.cf,
-       **      /usr/lib/sendmail.cf, and so forth.
-       */
-
-       strcpy(cbuf, _PATH_SENDMAILCF);
-       i = strlen(cbuf);
-       if (strcmp(&cbuf[i - 3], ".cf") == 0)
-       {
-               char *p;
-               extern char Version[];
-
-               strcpy(&cbuf[i - 2], Version);
-               p = strchr(&cbuf[i - 2], '/');
-               if (p != NULL)
-                       *p = '\0';
-               p = &cbuf[strlen(cbuf)];
-               do
-               {
-                       int fd;
-
-                       strcpy(p, ".cf");
-                       if ((fd = open(cbuf, O_RDONLY, 0)) >= 0)
-                       {
-                               close(fd);
-                               return cbuf;
-                       }
-                       *p = '\0';
-               } while ((p = strrchr(&cbuf[i - 2], '.')) != NULL);
-       }
-#endif
        return _PATH_SENDMAILCF;
 }
 \f/*
        return _PATH_SENDMAILCF;
 }
 \f/*