Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package man for openSUSE:Factory checked in at 2024-02-09 23:51:45 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/man (Old) and /work/SRC/openSUSE:Factory/.man.new.1815 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "man" Fri Feb 9 23:51:45 2024 rev:99 rq:1145198 version:2.12.0 Changes: -------- --- /work/SRC/openSUSE:Factory/man/man.changes 2024-01-26 22:46:21.290226521 +0100 +++ /work/SRC/openSUSE:Factory/.man.new.1815/man.changes 2024-02-09 23:51:52.301994834 +0100 @@ -1,0 +2,5 @@ +Thu Feb 8 10:48:51 UTC 2024 - Dr. Werner Fink <[email protected]> + +- Make lua scriplets more failsafe (boo#1219370) + +------------------------------------------------------------------- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ man.spec ++++++ --- /var/tmp/diff_new_pack.eLv4yn/_old 2024-02-09 23:51:53.066022366 +0100 +++ /var/tmp/diff_new_pack.eLv4yn/_new 2024-02-09 23:51:53.066022366 +0100 @@ -286,10 +286,22 @@ %filetriggerin -p <lua> -- %{_mandir} %endif %trigger_functions -stat = posix.stat("/var/cache/man/index.db") +stat = posix.stat("%{_localstatedir}/cache/man/index.db") if stat then execute("%{_bindir}/mandb", "--quiet") else + domkdir = false + stat = posix.stat("%{_localstatedir}/cache/man") + if not stat then + domkdir = true + elseif not (stat.type == "directory") then + domkdir = true + os.remove("%{_localstatedir}/cache/man") + end + if domkdir then + posix.mkdir("%{_localstatedir}/cache/man") + posix.chown("%{_localstatedir}/cache/man", "man", "man") + end execute("%{_bindir}/mandb", "--quiet", "--create") end @@ -299,10 +311,22 @@ %filetriggerpostun -p <lua> -- %{_mandir} %endif %trigger_functions -stat = posix.stat("/var/cache/man/index.db") +stat = posix.stat("%{_localstatedir}/cache/man/index.db") if stat then execute("%{_bindir}/mandb", "--quiet") else + domkdir = false + stat = posix.stat("%{_localstatedir}/cache/man") + if not stat then + domkdir = true + elseif not (stat.type == "directory") then + domkdir = true + os.remove("%{_localstatedir}/cache/man") + end + if domkdir then + posix.mkdir("%{_localstatedir}/cache/man") + posix.chown("%{_localstatedir}/cache/man", "man", "man") + end execute("%{_bindir}/mandb", "--quiet", "--create") end @@ -332,7 +356,7 @@ fi # Simply for systemdless containers getent group man > /dev/null || groupadd -r man -getent passwd man > /dev/null || useradd -r -g man -d /var/cache/man -s /sbin/nologin -c "Manual pages viewer" man +getent passwd man > /dev/null || useradd -r -g man -d %{_localstatedir}/cache/man -s /sbin/nologin -c "Manual pages viewer" man %post %{fillup_only -an cron} @@ -367,6 +391,7 @@ then # Simply for systemdless containers umask 022 + rm -f %{_localstatedir}/cache/man mkdir -p %{_localstatedir}/cache/man chown -R man:man %{_localstatedir}/cache/man fi
