dbiIndex db3Free(dbiIndex dbi)
{
if (dbi) {
- dbi->dbi_root = _free(dbi->dbi_root);
- dbi->dbi_home = _free(dbi->dbi_home);
- dbi->dbi_file = _free(dbi->dbi_file);
- dbi->dbi_subfile = _free(dbi->dbi_subfile);
- dbi->dbi_tmpdir = _free(dbi->dbi_tmpdir);
+ dbi->dbi_root = _constfree(dbi->dbi_root);
+ dbi->dbi_home = _constfree(dbi->dbi_home);
+ dbi->dbi_file = _constfree(dbi->dbi_file);
+ dbi->dbi_subfile = _constfree(dbi->dbi_subfile);
+ dbi->dbi_tmpdir = _constfree(dbi->dbi_tmpdir);
dbi->dbi_host = _free(dbi->dbi_host);
- dbi->dbi_errpfx = _free(dbi->dbi_errpfx);
- dbi->dbi_re_source = _free(dbi->dbi_re_source);
+ dbi->dbi_errpfx = _constfree(dbi->dbi_errpfx);
+ dbi->dbi_re_source = _constfree(dbi->dbi_re_source);
dbi->dbi_stats = _free(dbi->dbi_stats);
dbi = _free(dbi);
}
if (xx && rc == 0) rc = xx;
db->_dbi[dbix] = NULL;
}
- db->db_errpfx = _free(db->db_errpfx);
- db->db_root = _free(db->db_root);
- db->db_home = _free(db->db_home);
+ db->db_errpfx = _constfree(db->db_errpfx);
+ db->db_root = _constfree(db->db_root);
+ db->db_home = _constfree(db->db_home);
db->db_bits = PBM_FREE(db->db_bits);
db->_dbi = _free(db->_dbi);
db->db_home = rpmGetPath( (home && *home ? home : _DB_HOME), NULL);
if (!(db->db_home && db->db_home[0] != '%')) {
rpmlog(RPMLOG_ERR, _("no dbpath has been set\n"));
- db->db_root = _free(db->db_root);
- db->db_home = _free(db->db_home);
+ db->db_root = _constfree(db->db_root);
+ db->db_home = _constfree(db->db_home);
db = _free(db);
return NULL;
}
dbi->dbi_subfile);
dbi->dbi_stats = _free(dbi->dbi_stats);
- dbi->dbi_file = _free(dbi->dbi_file);
+ dbi->dbi_file = _constfree(dbi->dbi_file);
dbi->dbi_db = _free(dbi->dbi_db);
leaveChroot(dbi);