Skip to content
Snippets Groups Projects
Commit 0a4ff4f5 authored by Natanael Copa's avatar Natanael Copa
Browse files

commit: fix segfault

apk would try run the trigger even if package failed to install.
parent 065427f4
No related branches found
No related tags found
No related merge requests found
......@@ -206,7 +206,7 @@ static void run_triggers(struct apk_database *db, struct apk_changeset *changese
if (pkg == NULL)
continue;
ipkg = pkg->ipkg;
if (ipkg->pending_triggers->num == 0)
if (ipkg == NULL || ipkg->pending_triggers->num == 0)
continue;
*apk_string_array_add(&ipkg->pending_triggers) = NULL;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment