From b9601b1e597c64df9d04678509c31f9bab538fd2 Mon Sep 17 00:00:00 2001 From: Andrew Gregory Date: Mon, 3 Feb 2014 12:09:18 -0500 Subject: alpm: export *_free functions Front-ends should be able to free memory that alpm hands them. Signed-off-by: Andrew Gregory Signed-off-by: Allan McRae --- lib/libalpm/sync.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) (limited to 'lib/libalpm/sync.c') diff --git a/lib/libalpm/sync.c b/lib/libalpm/sync.c index 4a76438e..fb133248 100644 --- a/lib/libalpm/sync.c +++ b/lib/libalpm/sync.c @@ -451,7 +451,8 @@ int _alpm_sync_prepare(alpm_handle_t *handle, alpm_list_t **data) dependency-reordered list below */ handle->pm_errno = 0; if(data) { - alpm_list_free_inner(*data, (alpm_list_fn_free)_alpm_depmiss_free); + alpm_list_free_inner(*data, + (alpm_list_fn_free)alpm_depmissing_free); alpm_list_free(*data); *data = NULL; } @@ -527,7 +528,7 @@ int _alpm_sync_prepare(alpm_handle_t *handle, alpm_list_t **data) *data = alpm_list_add(*data, newconflict); } } - alpm_list_free_inner(deps, (alpm_list_fn_free)_alpm_conflict_free); + alpm_list_free_inner(deps, (alpm_list_fn_free)alpm_conflict_free); alpm_list_free(deps); _alpm_dep_free(dep1); _alpm_dep_free(dep2); @@ -545,7 +546,7 @@ int _alpm_sync_prepare(alpm_handle_t *handle, alpm_list_t **data) trans->unresolvable = alpm_list_add(trans->unresolvable, rsync); } - alpm_list_free_inner(deps, (alpm_list_fn_free)_alpm_conflict_free); + alpm_list_free_inner(deps, (alpm_list_fn_free)alpm_conflict_free); alpm_list_free(deps); deps = NULL; @@ -591,13 +592,13 @@ int _alpm_sync_prepare(alpm_handle_t *handle, alpm_list_t **data) *data = alpm_list_add(*data, newconflict); } } - alpm_list_free_inner(deps, (alpm_list_fn_free)_alpm_conflict_free); + alpm_list_free_inner(deps, (alpm_list_fn_free)alpm_conflict_free); alpm_list_free(deps); goto cleanup; } } EVENT(handle, ALPM_EVENT_INTERCONFLICTS_DONE, NULL, NULL); - alpm_list_free_inner(deps, (alpm_list_fn_free)_alpm_conflict_free); + alpm_list_free_inner(deps, (alpm_list_fn_free)alpm_conflict_free); alpm_list_free(deps); } @@ -627,7 +628,8 @@ int _alpm_sync_prepare(alpm_handle_t *handle, alpm_list_t **data) if(data) { *data = deps; } else { - alpm_list_free_inner(deps, (alpm_list_fn_free)_alpm_depmiss_free); + alpm_list_free_inner(deps, + (alpm_list_fn_free)alpm_depmissing_free); alpm_list_free(deps); } goto cleanup; @@ -1273,7 +1275,7 @@ int _alpm_sync_commit(alpm_handle_t *handle, alpm_list_t **data) if(data) { *data = conflict; } else { - alpm_list_free_inner(conflict, (alpm_list_fn_free)_alpm_fileconflict_free); + alpm_list_free_inner(conflict, (alpm_list_fn_free)alpm_fileconflict_free); alpm_list_free(conflict); } RET_ERR(handle, ALPM_ERR_FILE_CONFLICTS, -1); -- cgit v1.2.3-24-g4f1b