From: Michael Tremer Date: Sat, 13 Feb 2021 16:28:42 +0000 (+0000) Subject: pakfire: Skip deactivation when running in / X-Git-Tag: 0.9.28~1285^2~729 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9b4e463defeee5e6bcc27a9bb834f936d43388bb;p=pakfire.git pakfire: Skip deactivation when running in / Signed-off-by: Michael Tremer --- diff --git a/src/libpakfire/pakfire.c b/src/libpakfire/pakfire.c index b11dae969..00b01b57f 100644 --- a/src/libpakfire/pakfire.c +++ b/src/libpakfire/pakfire.c @@ -458,6 +458,9 @@ PAKFIRE_EXPORT int pakfire_activate(Pakfire pakfire) { } PAKFIRE_EXPORT int pakfire_deactivate(Pakfire pakfire) { + if (strcmp(pakfire->path, "/") == 0) + return 0; + // Do nothing if there are some activations left if (--pakfire->activated > 0) return 0;