hdb/hdb-mitdb: Nix unused variable key_data in mdb_seq.
key_data is unused. Presumably this was copypasta from DB_seq in hdb/db.c, where it is used for the Heimdal database format in which the value may be missing a principal but it can be recovered from the key. In contrast, the mit-krb5 format appears to always store the principal in the value and _hdb_mdb_value2entry always retrieves it, with no need for a key2principal fallback. fix https://github.com/heimdal/heimdal/issues/1102
This commit is contained in:

committed by
Nico Williams

parent
1d2233f907
commit
e3e271ff70
@@ -769,7 +769,7 @@ mdb_seq(krb5_context context, HDB *db,
|
|||||||
{
|
{
|
||||||
DB *d = (DB*)db->hdb_db;
|
DB *d = (DB*)db->hdb_db;
|
||||||
DBT key, value;
|
DBT key, value;
|
||||||
krb5_data key_data, data;
|
krb5_data data;
|
||||||
int code;
|
int code;
|
||||||
|
|
||||||
code = db->hdb_lock(context, db, HDB_RLOCK);
|
code = db->hdb_lock(context, db, HDB_RLOCK);
|
||||||
@@ -790,8 +790,6 @@ mdb_seq(krb5_context context, HDB *db,
|
|||||||
return HDB_ERR_NOENTRY;
|
return HDB_ERR_NOENTRY;
|
||||||
}
|
}
|
||||||
|
|
||||||
key_data.data = key.data;
|
|
||||||
key_data.length = key.size;
|
|
||||||
data.data = value.data;
|
data.data = value.data;
|
||||||
data.length = value.size;
|
data.length = value.size;
|
||||||
memset(entry, 0, sizeof(*entry));
|
memset(entry, 0, sizeof(*entry));
|
||||||
|
Reference in New Issue
Block a user