(hdb_create): check for dynamic backend after static to avoid warning

from dynamic backend when using a known static backend


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12445 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2003-07-18 08:03:07 +00:00
parent 7bafce13ca
commit 41e7cd2af1

View File

@@ -317,17 +317,17 @@ find_method (const char *filename, const char **rest)
krb5_error_code
hdb_create(krb5_context context, HDB **db, const char *filename)
{
const struct hdb_method *h = NULL;
const struct hdb_method *h;
const char *residual;
if(filename == NULL)
filename = HDB_DEFAULT_DB;
krb5_add_et_list(context, initialize_hdb_error_table_r);
h = find_method (filename, &residual);
#ifdef HAVE_DLOPEN
h = find_dynamic_method (context, filename, &residual);
#endif
if (h == NULL)
h = find_method (filename, &residual);
h = find_dynamic_method (context, filename, &residual);
#endif
if (h == NULL)
krb5_errx(context, 1, "No database support! (hdb_create)");
return (*h->create)(context, db, residual);