index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Chantry Xavier <shiningxc@gmail.com> | 2007-11-21 17:10:20 +0100 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2007-11-25 14:00:38 -0600 |
commit | 8bee526d28eaad45e0e1e210cd523e157c71cfae (patch) | |
tree | 31231c33805c4f846564e40294111f0141a2f7ca /lib/libalpm/trans.c | |
parent | f5d2150e9db9205a9f208d4144b6d0381f877ad3 (diff) |
-rw-r--r-- | lib/libalpm/trans.c | 10 |
diff --git a/lib/libalpm/trans.c b/lib/libalpm/trans.c index 19ae2b6c..d9988265 100644 --- a/lib/libalpm/trans.c +++ b/lib/libalpm/trans.c @@ -246,8 +246,6 @@ pmtrans_t *_alpm_trans_new() void _alpm_trans_free(pmtrans_t *trans) { - alpm_list_t *i; - ALPM_LOG_FUNC; if(trans == NULL) { @@ -256,13 +254,9 @@ void _alpm_trans_free(pmtrans_t *trans) FREELIST(trans->targets); if(trans->type == PM_TRANS_TYPE_SYNC) { - for(i = trans->packages; i; i = alpm_list_next(i)) { - _alpm_sync_free(i->data); - } + alpm_list_free_inner(trans->packages, (alpm_list_fn_free)_alpm_sync_free); } else { - for(i = trans->packages; i; i = alpm_list_next(i)) { - _alpm_pkg_free(i->data); - } + alpm_list_free_inner(trans->packages, (alpm_list_fn_free)_alpm_pkg_free); } alpm_list_free(trans->packages); |