From: Michael Tremer Date: Sat, 11 Jan 2025 16:27:22 +0000 (+0000) Subject: archive: Fail if we were not given a package pointer X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=fa010a9678f4c5da5c3a047012defcb54dba6526;p=people%2Fric9%2Fpakfire.git archive: Fail if we were not given a package pointer Signed-off-by: Michael Tremer --- diff --git a/src/pakfire/archive.c b/src/pakfire/archive.c index 602f195d2..8a6438127 100644 --- a/src/pakfire/archive.c +++ b/src/pakfire/archive.c @@ -1778,6 +1778,10 @@ int pakfire_archive_make_package(struct pakfire_archive* archive, struct pakfire_repo* dummy = NULL; int r; + // Check inputs + if (!package) + return -EINVAL; + // Use dummy repo if no repository was passed if (!repo) { dummy = pakfire_get_repo(archive->pakfire, PAKFIRE_REPO_DUMMY);