X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;ds=sidebyside;f=servers%2Fslapd%2Fmain.c;h=b32e60e4d26383194db389118be898394d22d1ad;hb=4f302fd19714591bd94bbf2a160dd8ecc704d693;hp=3fe61d6c07001163ad1b7d1abd71aa916435a283;hpb=06782dac3bab158838920005b11373554a3655fd;p=openldap
diff --git a/servers/slapd/main.c b/servers/slapd/main.c
index 3fe61d6c07..b32e60e4d2 100644
--- a/servers/slapd/main.c
+++ b/servers/slapd/main.c
@@ -1,7 +1,7 @@
/* $OpenLDAP$ */
/* This work is part of OpenLDAP Software .
*
- * Copyright 1998-2004 The OpenLDAP Foundation.
+ * Copyright 1998-2005 The OpenLDAP Foundation.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -27,6 +27,7 @@
#include
+#include
#include
#include
#include
@@ -34,8 +35,6 @@
#include
#include
-#include "ldap_pvt.h"
-
#include "slap.h"
#include "lutil.h"
#include "ldif.h"
@@ -100,7 +99,6 @@ const char Versionstr[] =
#endif
#ifdef LOG_LOCAL4
-
#define DEFAULT_SYSLOG_USER LOG_LOCAL4
typedef struct _str2intDispatch {
@@ -109,7 +107,6 @@ typedef struct _str2intDispatch {
int intVal;
} STRDISP, *STRDISP_P;
-
/* table to compute syslog-options to integer */
static STRDISP syslog_types[] = {
{ "LOCAL0", sizeof("LOCAL0"), LOG_LOCAL0 },
@@ -120,11 +117,16 @@ static STRDISP syslog_types[] = {
{ "LOCAL5", sizeof("LOCAL5"), LOG_LOCAL5 },
{ "LOCAL6", sizeof("LOCAL6"), LOG_LOCAL6 },
{ "LOCAL7", sizeof("LOCAL7"), LOG_LOCAL7 },
+#ifdef LOG_USER
+ { "USER", sizeof("USER"), LOG_USER },
+#endif
+#ifdef LOG_DAEMON
+ { "DAEMON", sizeof("DAEMON"), LOG_DAEMON },
+#endif
{ NULL, 0, 0 }
};
-static int cnvt_str2int( char *, STRDISP_P, int );
-
+static int cnvt_str2int( char *, STRDISP_P, int );
#endif /* LOG_LOCAL4 */
#define CHECK_NONE 0x00
@@ -160,13 +162,27 @@ slapd_opt_slp( const char *val, void *arg )
#endif
}
+/*
+ * Option helper structure:
+ *
+ * oh_nam is left-hand part of