summaryrefslogtreecommitdiffstats
path: root/lib/libalpm/add.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libalpm/add.c')
-rw-r--r--lib/libalpm/add.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/libalpm/add.c b/lib/libalpm/add.c
index ebcd6a55..dc565ac6 100644
--- a/lib/libalpm/add.c
+++ b/lib/libalpm/add.c
@@ -483,6 +483,8 @@ static int commit_single_pkg(pmpkg_t *newpkg, int pkg_current, int pkg_count,
ALPM_LOG_FUNC;
+ ASSERT(trans != NULL, RET_ERR(PM_ERR_TRANS_NULL, -1));
+
snprintf(scriptlet, PATH_MAX, "%s%s-%s/install",
_alpm_db_path(db), alpm_pkg_get_name(newpkg),
alpm_pkg_get_version(newpkg));