index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Dan McGee <dan@archlinux.org> | 2012-05-04 11:41:40 -0500 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2012-05-04 11:41:40 -0500 |
commit | 1bf05e706b5edac92e9c913a69ca8686c6440f8b (patch) | |
tree | ec0cf53f4635e93d195c8874082dfa5117daf634 /lib/libalpm/add.c | |
parent | 5f71570ec48588bf24bfe786f40b500216084d07 (diff) |
-rw-r--r-- | lib/libalpm/add.c | 5 |
diff --git a/lib/libalpm/add.c b/lib/libalpm/add.c index 6c2f0cb6..c49d99b4 100644 --- a/lib/libalpm/add.c +++ b/lib/libalpm/add.c @@ -488,8 +488,9 @@ static int commit_single_pkg(alpm_handle_t *handle, alpm_pkg_t *newpkg, if(alpm_pkg_has_scriptlet(newpkg) && !(trans->flags & ALPM_TRANS_FLAG_NOSCRIPTLET)) { const char *scriptlet_name = is_upgrade ? "pre_upgrade" : "pre_install"; - _alpm_runscriptlet(handle, pkgfile, - scriptlet_name, newpkg->version, NULL, 1); + + _alpm_runscriptlet(handle, pkgfile, scriptlet_name, + newpkg->version, oldpkg ? oldpkg->version : NULL, 1); } /* we override any pre-set reason if we have alldeps or allexplicit set */ |