Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/lib/libalpm/add.c
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-04-21 22:09:57 -0500
committerDan McGee <dan@archlinux.org>2011-04-22 15:58:34 -0500
commite39c104d13bfb6e2c055c2af3eee41bfa603b13b (patch)
tree2c38dc4d244668589b80c236bbac62e4161d990a /lib/libalpm/add.c
parent53c749ce0aa55307fff2b419501da509212ae9ba (diff)
cleanup: add_pkg() and remove_pkg()
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'lib/libalpm/add.c')
-rw-r--r--lib/libalpm/add.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/libalpm/add.c b/lib/libalpm/add.c
index 44e3eb9f..ee56e876 100644
--- a/lib/libalpm/add.c
+++ b/lib/libalpm/add.c
@@ -63,11 +63,10 @@ int SYMEXPORT alpm_add_pkg(pmpkg_t *pkg)
trans = handle->trans;
ASSERT(trans != NULL, RET_ERR(PM_ERR_TRANS_NULL, -1));
ASSERT(trans->state == STATE_INITIALIZED, RET_ERR(PM_ERR_TRANS_NOT_INITIALIZED, -1));
- ASSERT(trans != NULL, RET_ERR(PM_ERR_TRANS_NULL, -1));
db_local = handle->db_local;
- pkgname = alpm_pkg_get_name(pkg);
- pkgver = alpm_pkg_get_version(pkg);
+ pkgname = pkg->name;
+ pkgver = pkg->version;
_alpm_log(PM_LOG_DEBUG, "adding package '%s'\n", pkgname);
@@ -100,7 +99,7 @@ int SYMEXPORT alpm_add_pkg(pmpkg_t *pkg)
/* add the package to the transaction */
pkg->reason = PM_PKG_REASON_EXPLICIT;
- _alpm_log(PM_LOG_DEBUG, "adding package %s-%s to the transaction targets\n",
+ _alpm_log(PM_LOG_DEBUG, "adding package %s-%s to the transaction add list\n",
pkgname, pkgver);
trans->add = alpm_list_add(trans->add, pkg);