]> granicus.if.org Git - apache/commitdiff
Make mod_auth_dbm compile cleanly.
authorRyan Bloom <rbb@apache.org>
Mon, 30 Oct 2000 20:45:38 +0000 (20:45 +0000)
committerRyan Bloom <rbb@apache.org>
Mon, 30 Oct 2000 20:45:38 +0000 (20:45 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@86769 13f79535-47bb-0310-9956-ffa450edef68

modules/aaa/mod_auth_dbm.c

index fc2b4bb853803859353fa1fc11a8829556685518..c00cc699a883d86748731ea2f600ee8c79fb85b8 100644 (file)
@@ -125,7 +125,7 @@ static void *create_dbm_auth_dir_config(apr_pool_t *p, char *d)
     return sec;
 }
 
-static const char *set_dbm_slot(cmd_parms *cmd, void *offset, char *f, char *t)
+static const char *set_dbm_slot(cmd_parms *cmd, void *offset, const char *f, const char *t)
 {
     if (!t || strcmp(t, "dbm"))
        return DECLINE_CMD;
@@ -135,21 +135,21 @@ static const char *set_dbm_slot(cmd_parms *cmd, void *offset, char *f, char *t)
 
 static const command_rec dbm_auth_cmds[] =
 {
-    {"AuthDBMUserFile", ap_set_file_slot,
+    AP_INIT_TAKE1("AuthDBMUserFile", ap_set_file_slot,
      (void *) XtOffsetOf(dbm_auth_config_rec, auth_dbmpwfile),
-     OR_AUTHCFG, TAKE1, NULL},
-    {"AuthDBMGroupFile", ap_set_file_slot,
+     OR_AUTHCFG, NULL),
+    AP_INIT_TAKE1("AuthDBMGroupFile", ap_set_file_slot,
      (void *) XtOffsetOf(dbm_auth_config_rec, auth_dbmgrpfile),
-     OR_AUTHCFG, TAKE1, NULL},
-    {"AuthUserFile", set_dbm_slot,
+     OR_AUTHCFG, NULL),
+    AP_INIT_TAKE12("AuthUserFile", set_dbm_slot,
      (void *) XtOffsetOf(dbm_auth_config_rec, auth_dbmpwfile),
-     OR_AUTHCFG, TAKE12, NULL},
-    {"AuthGroupFile", set_dbm_slot,
+     OR_AUTHCFG, NULL),
+    AP_INIT_TAKE12("AuthGroupFile", set_dbm_slot,
      (void *) XtOffsetOf(dbm_auth_config_rec, auth_dbmgrpfile),
-     OR_AUTHCFG, TAKE12, NULL},
-    {"AuthDBMAuthoritative", ap_set_flag_slot,
+     OR_AUTHCFG, NULL),
+    AP_INIT_FLAG("AuthDBMAuthoritative", ap_set_flag_slot,
      (void *) XtOffsetOf(dbm_auth_config_rec, auth_dbmauthoritative),
-     OR_AUTHCFG, FLAG, "Set to 'no' to allow access control to be passed along to lower modules, if the UserID is not known in this module"},
+     OR_AUTHCFG, "Set to 'no' to allow access control to be passed along to lower modules, if the UserID is not known in this module"),
     {NULL}
 };
 
@@ -160,8 +160,9 @@ static char *get_dbm_pw(request_rec *r, char *user, char *auth_dbmpwfile)
     DBM *f;
     datum d, q;
     char *pw = NULL;
+#ifdef WIN32 /* this is only used on Windows, so only define it on Windows */
     apr_status_t retval;
-
+#endif
     q.dptr = user;
 #ifndef NETSCAPE_DBM_COMPAT
     q.dsize = strlen(q.dptr);