mirror of
https://github.com/moparisthebest/pacman
synced 2024-12-22 15:58:50 -05:00
* Fix up _alpm_db_free, remove use of void*.
This commit is contained in:
parent
13e2111045
commit
4a45a273ea
@ -78,13 +78,11 @@ pmdb_t *_alpm_db_new(const char *root, const char *dbpath, const char *treename)
|
||||
return(db);
|
||||
}
|
||||
|
||||
void _alpm_db_free(void *data)
|
||||
void _alpm_db_free(pmdb_t *db)
|
||||
{
|
||||
pmdb_t *db = data;
|
||||
|
||||
ALPM_LOG_FUNC;
|
||||
|
||||
FREELISTSERVERS(db->servers);
|
||||
_FREELIST(db->servers, _alpm_server_free);
|
||||
FREE(db->path);
|
||||
FREE(db);
|
||||
|
||||
|
@ -48,7 +48,7 @@ struct __pmdb_t {
|
||||
|
||||
/* db.c, database general calls */
|
||||
pmdb_t *_alpm_db_new(const char *root, const char *dbpath, const char *treename);
|
||||
void _alpm_db_free(void *data);
|
||||
void _alpm_db_free(pmdb_t *db);
|
||||
int _alpm_db_cmp(const void *db1, const void *db2);
|
||||
alpm_list_t *_alpm_db_search(pmdb_t *db, alpm_list_t *needles);
|
||||
pmdb_t *_alpm_db_register(const char *treename, alpm_cb_db_register callback);
|
||||
|
@ -28,7 +28,6 @@
|
||||
#include <download.h>
|
||||
|
||||
#define FREESERVER(p) do { if(p){_alpm_server_free(p); p = NULL;}} while(0)
|
||||
#define FREELISTSERVERS(p) _FREELIST(p, _alpm_server_free)
|
||||
|
||||
/* Servers */
|
||||
struct __pmserver_t {
|
||||
|
Loading…
Reference in New Issue
Block a user