Fix memleak when querying package file(s)

Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
Dan McGee 2007-11-25 14:12:00 -06:00
parent 6e8daa553b
commit c36b0f32c6
1 changed files with 5 additions and 0 deletions

View File

@ -392,6 +392,11 @@ int pacman_query(alpm_list_t *targets)
if(filter(pkg)) {
display(pkg);
}
if(config->op_q_isfile) {
alpm_pkg_free(pkg);
pkg = NULL;
}
}
return(ret);