mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-04 13:29:59 -05:00
hashmap: Use pa_free_cb_t instead of pa_free2_cb_t
The previous patch removed module-gconf's dependency on the userdata pointer of the free callback, and that was the only place where the userdata pointer of pa_free2_cb_t was used, so now there's no need for pa_free2_cb_t in pa_hashmap_free(). Using pa_free_cb_t instead allows removing a significant amount of repetitive code.
This commit is contained in:
parent
dcf043842e
commit
8872c238ba
41 changed files with 112 additions and 308 deletions
|
|
@ -264,10 +264,9 @@ void pa_database_close(pa_database *database) {
|
|||
pa_assert(db);
|
||||
|
||||
pa_database_sync(database);
|
||||
pa_database_clear(database);
|
||||
pa_xfree(db->filename);
|
||||
pa_xfree(db->tmp_filename);
|
||||
pa_hashmap_free(db->map, NULL, NULL);
|
||||
pa_hashmap_free(db->map, (pa_free_cb_t) free_entry);
|
||||
pa_xfree(db);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue