Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAurelien Foret <aurelien@archlinux.org>2005-03-16 20:09:10 +0000
committerAurelien Foret <aurelien@archlinux.org>2005-03-16 20:09:10 +0000
commit7c04b050ea6d194392b82165ce08e89e97e4127c (patch)
tree906328c9c016e41da6978c9609cb00cb2df7172c
parentb0f613c2115f00129d4bdeaa705a0964e53b29b2 (diff)
Make sure we generate a UPGRADE_DONE event during upgrades
-rw-r--r--lib/libalpm/add.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libalpm/add.c b/lib/libalpm/add.c
index 325dbc86..d6e4d9d8 100644
--- a/lib/libalpm/add.c
+++ b/lib/libalpm/add.c
@@ -561,10 +561,10 @@ int add_commit(pmdb_t *db, pmtrans_t *trans)
_alpm_runscriptlet(handle->root, pm_install, "post_install", info->version, NULL);
}
- if(pmo_upgrade && oldpkg) {
+ if(pmo_upgrade) {
TRANS_CB(trans, PM_TRANS_EVT_UPGRADE_DONE, info, NULL);
alpm_logaction("upgraded %s (%s -> %s)", info->name,
- oldpkg->version, info->version);
+ oldpkg ? oldpkg->version : NULL, info->version);
} else {
TRANS_CB(trans, PM_TRANS_EVT_ADD_DONE, info, NULL);
alpm_logaction("installed %s (%s)", info->name, info->version);