From da1258df32aeb744cd0ad35f59fbbb648566e16a Mon Sep 17 00:00:00 2001 From: Pierre Pronchery Date: Fri, 22 Mar 2019 18:58:27 +0100 Subject: [PATCH] Exit directly when nothing is to be done --- actions.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/actions.c b/actions.c index 564877b..6195e66 100644 --- a/actions.c +++ b/actions.c @@ -610,6 +610,9 @@ pkgin_install(char **opkgargs, int do_inst) printf("%d to refresh, %d to upgrade, %d to install\n", refreshnum, upgradenum, installnum); printf("%s to download, %s to install\n", h_fsize, h_psize); + + if (refreshnum == 0 && upgradenum == 0 && installnum == 0) + exit(rc); } else { printf("%d package%s to download:\n%s\n", downloadnum, (downloadnum == 1) ? "" : "s", todownload);