htable: Fix memory leak when reloading an empty htable from database
@@ -247,6 +247,7 @@ int ht_db_load_table(ht_t *ht, str *dbtable, int mode)
} else {
if(RES_ROW_N(db_res)==0)
{
+ ht_dbf.free_result(ht_db_con, db_res);
LM_DBG("Nothing to be loaded in hash table\n");
return 0;
}