apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From minf...@apache.org
Subject svn commit: r1890966 - /apr/apr/trunk/dbm/apr_dbm.c
Date Tue, 22 Jun 2021 11:04:17 GMT
Author: minfrin
Date: Tue Jun 22 11:04:17 2021
New Revision: 1890966

URL: http://svn.apache.org/viewvc?rev=1890966&view=rev
Log:
Fall back on default if the dbm type is unset.

Modified:
    apr/apr/trunk/dbm/apr_dbm.c

Modified: apr/apr/trunk/dbm/apr_dbm.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/dbm/apr_dbm.c?rev=1890966&r1=1890965&r2=1890966&view=diff
==============================================================================
--- apr/apr/trunk/dbm/apr_dbm.c (original)
+++ apr/apr/trunk/dbm/apr_dbm.c Tue Jun 22 11:04:17 2021
@@ -86,6 +86,10 @@ APR_DECLARE(apr_status_t) apr_dbm_get_dr
         *result = NULL; /* until further notice */
     }
 
+    if (!type) {
+    	type = DBM_NAME;
+    }
+
     *vtable = NULL;
     if (!strcasecmp(type, "default"))     *vtable = &DBM_VTABLE;
 #if APU_HAVE_DB
@@ -133,6 +137,10 @@ APR_DECLARE(apr_status_t) apr_dbm_get_dr
         *result = NULL; /* until further notice */
     }
 
+    if (!type) {
+    	type = DBM_NAME;
+    }
+
     if (!strcasecmp(type, "default"))        type = DBM_NAME;
     else if (!strcasecmp(type, "db"))        type = "db";
     else if (*type && !strcasecmp(type + 1, "dbm")) {



Mime
View raw message