From c79da92385c5ea5dc9ef9f82c3025649ab7056f8 Mon Sep 17 00:00:00 2001 From: tigro Date: Sat, 23 Dec 2023 00:18:25 +0300 Subject: [PATCH] Add safeguard in triggers --- SOURCES/triggers.systemd | 16 ++++++++-------- SPECS/systemd.spec | 5 ++++- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/SOURCES/triggers.systemd b/SOURCES/triggers.systemd index 90906e3..e59861d 100644 --- a/SOURCES/triggers.systemd +++ b/SOURCES/triggers.systemd @@ -29,7 +29,7 @@ # installed, because other cases are covered by the *un scriptlets, # so sometimes we will reload needlessly. if test -d /run/systemd/system; then - %{_bindir}/systemctl daemon-reload + %{_bindir}/systemctl daemon-reload ||: fi %transfiletriggerun -- /usr/lib/systemd/system /etc/systemd/system @@ -54,7 +54,7 @@ fi %filetriggerpostun -P 1000100 -- /usr/lib/systemd/system /etc/systemd/system if test -f "%{_localstatedir}/lib/rpm-state/systemd/needs-reload"; then rm -rf "%{_localstatedir}/lib/rpm-state/systemd" - %{_bindir}/systemctl daemon-reload + %{_bindir}/systemctl daemon-reload ||: fi %transfiletriggerin -P 100700 -- /usr/lib/sysusers.d @@ -62,7 +62,7 @@ fi # specified users automatically. The priority is set such that it # will run before the tmpfiles file trigger. if test -d /run/systemd/system; then - %{_bindir}/systemd-sysusers + %{_bindir}/systemd-sysusers ||: fi %transfiletriggerin -P 100500 -- /usr/lib/tmpfiles.d @@ -70,35 +70,35 @@ fi # tmpfiles automatically. The priority is set such that it will run # after the sysusers file trigger, but before any other triggers. if test -d /run/systemd/system; then - %{_bindir}/systemd-tmpfiles --create + %{_bindir}/systemd-tmpfiles --create ||: fi %transfiletriggerin udev -- /usr/lib/udev/hwdb.d # This script will automatically invoke hwdb update if files have been # installed or updated in /usr/lib/udev/hwdb.d. if test -d /run/systemd/system; then - %{_bindir}/systemd-hwdb update + %{_bindir}/systemd-hwdb update ||: fi %transfiletriggerin -- /usr/lib/systemd/catalog # This script will automatically invoke journal catalog update if files # have been installed or updated in /usr/lib/systemd/catalog. if test -d /run/systemd/system; then - %{_bindir}/journalctl --update-catalog + %{_bindir}/journalctl --update-catalog ||: fi %transfiletriggerin udev -- /usr/lib/udev/rules.d # This script will automatically update udev with new rules if files # have been installed or updated in /usr/lib/udev/rules.d. if test -d /run/systemd/system; then - %{_bindir}/udevadm control --reload + %{_bindir}/udevadm control --reload ||: fi %transfiletriggerin -- /usr/lib/sysctl.d # This script will automatically apply sysctl rules if files have been # installed or updated in /usr/lib/sysctl.d. if test -d /run/systemd/system; then - /usr/lib/systemd/systemd-sysctl + /usr/lib/systemd/systemd-sysctl ||: fi %transfiletriggerin -- /usr/lib/binfmt.d diff --git a/SPECS/systemd.spec b/SPECS/systemd.spec index d9781d2..5cd270b 100644 --- a/SPECS/systemd.spec +++ b/SPECS/systemd.spec @@ -13,7 +13,7 @@ Name: systemd Url: http://www.freedesktop.org/wiki/Software/systemd Version: 239 -Release: 81%{?dist} +Release: 81%{?dist}.inferit # For a breakdown of the licensing, see README License: LGPLv2+ and MIT and GPLv2+ Summary: System and Service Manager @@ -1720,6 +1720,9 @@ fi - test: backport TEST-81-GENERATORS (fstab-generator only) (RHEL-1087) - resolved: actually check authenticated flag of SOA transaction (RHEL-6213) +* Fri Dec 22 2023 Arkady L. Shane - 239-78.inferit +- Add safeguard in triggers + * Tue Aug 22 2023 systemd maintenance team - 239-78 - login: add a missing error check for session_set_leader() (#2158167) - logind: reset session leader if we know for a fact that it is gone (#2158167)