From f5dfbccc541ff6b9acb1c86649b800c26c9a70ec Mon Sep 17 00:00:00 2001 From: Ken Raeburn Date: Tue, 10 Jun 2008 22:03:01 +0000 Subject: [PATCH] Get rid of handling of set-but-unused kadm5_config_params.admin_dbname git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@20383 dc483132-0cff-0310-8789-dd5450dbe970 --- src/kadmin/testing/util/tcl_kadm5.c | 6 +----- src/lib/kadm5/admin.h | 2 +- src/lib/kadm5/alt_prof.c | 14 ++------------ src/lib/kadm5/srv/server_init.c | 1 - 4 files changed, 4 insertions(+), 19 deletions(-) diff --git a/src/kadmin/testing/util/tcl_kadm5.c b/src/kadmin/testing/util/tcl_kadm5.c index 04a379570..a852f26a5 100644 --- a/src/kadmin/testing/util/tcl_kadm5.c +++ b/src/kadmin/testing/util/tcl_kadm5.c @@ -1037,11 +1037,7 @@ static int parse_config_params(Tcl_Interp *interp, char *list, retcode = TCL_ERROR; goto finished; } - if ((retcode = parse_str(interp, argv[5], ¶ms->admin_dbname)) != TCL_OK) { - Tcl_AppendElement(interp, "while parsing admin_dbname name"); - retcode = TCL_ERROR; - goto finished; - } + /* Ignore argv[5], which used to set the admin_dbname field. */ /* Ignore argv[6], which used to set the admin_lockfile field. */ if ((retcode = parse_str(interp, argv[7], ¶ms->admin_keytab)) != TCL_OK) { Tcl_AppendElement(interp, "while parsing admin_keytab name"); diff --git a/src/lib/kadm5/admin.h b/src/lib/kadm5/admin.h index 8c8c23dea..13ffc1b01 100644 --- a/src/lib/kadm5/admin.h +++ b/src/lib/kadm5/admin.h @@ -227,9 +227,9 @@ typedef struct _kadm5_config_params { #endif char * dbname; - char * admin_dbname; /* dummy fields to preserve abi for now */ + char * admin_dbname_was_here; char * admin_lockfile_was_here; char * admin_keytab; diff --git a/src/lib/kadm5/alt_prof.c b/src/lib/kadm5/alt_prof.c index f9c05d947..df89ccf87 100644 --- a/src/lib/kadm5/alt_prof.c +++ b/src/lib/kadm5/alt_prof.c @@ -464,18 +464,9 @@ krb5_error_code kadm5_get_config_params(context, use_kdc_config, params.mask |= KADM5_CONFIG_DBNAME; } - /* - * admin database name and lockfile are now always derived from dbname - */ - if (params.mask & KADM5_CONFIG_DBNAME) { - if (asprintf(¶ms.admin_dbname, "%s.kadm5", params.dbname) > 0) - params.mask |= KADM5_CONFIG_ADBNAME; - else - params.admin_dbname = NULL; - } - + params.admin_dbname_was_here = NULL; params.admin_lockfile_was_here = NULL; - /* never set KADM5_CONFIG_ADB_LOCKFILE */ + /* never set KADM5_CONFIG_ADBNAME, KADM5_CONFIG_ADB_LOCKFILE */ /* Get the value for the admin (policy) database lock file*/ hierarchy[2] = "admin_keytab"; @@ -757,7 +748,6 @@ kadm5_free_config_params(context, params) free(params->dict_file); free(params->acl_file); free(params->realm); - free(params->admin_dbname); } return(0); } diff --git a/src/lib/kadm5/srv/server_init.c b/src/lib/kadm5/srv/server_init.c index e00e3e055..dbb7ff78e 100644 --- a/src/lib/kadm5/srv/server_init.c +++ b/src/lib/kadm5/srv/server_init.c @@ -233,7 +233,6 @@ kadm5_ret_t kadm5_init(char *client_name, char *pass, } #define REQUIRED_PARAMS (KADM5_CONFIG_REALM | KADM5_CONFIG_DBNAME | \ - KADM5_CONFIG_ADBNAME | \ KADM5_CONFIG_ENCTYPE | \ KADM5_CONFIG_FLAGS | \ KADM5_CONFIG_MAX_LIFE | KADM5_CONFIG_MAX_RLIFE | \ -- 2.26.2