summaryrefslogtreecommitdiffstats
path: root/contrib/sendmail/praliases/praliases.c
diff options
context:
space:
mode:
authorgshapiro <gshapiro@FreeBSD.org>2001-02-28 00:19:57 +0000
committergshapiro <gshapiro@FreeBSD.org>2001-02-28 00:19:57 +0000
commit8d82727087db5182be90a20f20175cc720c5d1e5 (patch)
treef7a64a70968946b03a6d79fcded22b5a31689f6d /contrib/sendmail/praliases/praliases.c
parent167a83e7b8733416154f871e39e86ba77eb1554d (diff)
downloadFreeBSD-src-8d82727087db5182be90a20f20175cc720c5d1e5.zip
FreeBSD-src-8d82727087db5182be90a20f20175cc720c5d1e5.tar.gz
Import sendmail 8.11.3
Diffstat (limited to 'contrib/sendmail/praliases/praliases.c')
-rw-r--r--contrib/sendmail/praliases/praliases.c21
1 files changed, 18 insertions, 3 deletions
diff --git a/contrib/sendmail/praliases/praliases.c b/contrib/sendmail/praliases/praliases.c
index 8db0cd1..b40d19d 100644
--- a/contrib/sendmail/praliases/praliases.c
+++ b/contrib/sendmail/praliases/praliases.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998-2000 Sendmail, Inc. and its suppliers.
+ * Copyright (c) 1998-2001 Sendmail, Inc. and its suppliers.
* All rights reserved.
* Copyright (c) 1983 Eric P. Allman. All rights reserved.
* Copyright (c) 1988, 1993
@@ -13,7 +13,7 @@
#ifndef lint
static char copyright[] =
-"@(#) Copyright (c) 1998-2000 Sendmail, Inc. and its suppliers.\n\
+"@(#) Copyright (c) 1998-2001 Sendmail, Inc. and its suppliers.\n\
All rights reserved.\n\
Copyright (c) 1983 Eric P. Allman. All rights reserved.\n\
Copyright (c) 1988, 1993\n\
@@ -21,7 +21,7 @@ static char copyright[] =
#endif /* ! lint */
#ifndef lint
-static char id[] = "@(#)$Id: praliases.c,v 8.59.4.15 2000/10/24 00:42:59 geir Exp $";
+static char id[] = "@(#)$Id: praliases.c,v 8.59.4.18 2001/01/22 19:00:18 gshapiro Exp $";
#endif /* ! lint */
#include <sys/types.h>
@@ -272,6 +272,21 @@ praliases(filename, argc, argv)
db_name++;
}
+ /* Skip non-file based DB types */
+ if (db_type != NULL && *db_type != '\0')
+ {
+ if (db_type != SMDB_TYPE_DEFAULT &&
+ strcmp(db_type, "hash") != 0 &&
+ strcmp(db_type, "btree") != 0 &&
+ strcmp(db_type, "dbm") != 0)
+ {
+ fprintf(stderr,
+ "praliases: Skipping non-file based alias type %s\n",
+ db_type);
+ return;
+ }
+ }
+
if (*db_name == '\0' || (db_type != NULL && *db_type == '\0'))
{
if (colon != NULL)
OpenPOWER on IntegriCloud