fix: harden postrm guards to prevent fallthrough on empty arg and fix lock path

This commit is contained in:
Dushnilin
2026-09-09 07:40:59 +03:00
parent 8a56361bfd
commit 01dad3bab0
3 changed files with 17 additions and 9 deletions
+4 -2
View File
@@ -38,9 +38,11 @@ define Package/$(PKG_NAME)/postrm
[ -n "$${IPKG_INSTROOT}" ] && exit 0
[ "$$1" = "upgrade" ] && exit 0
[ "$$1" != "remove" ] && [ "$$1" != "purge" ] && [ -n "$$1" ] && exit 0
if [ "$$1" != "remove" ] && [ "$$1" != "purge" ]; then
exit 0
fi
if [ -f /var/run/tachyon/component-actions/action.lock ] || [ -f /tmp/run/tachyon/component-actions/action.lock ]; then
if [ -e /var/run/tachyon/component-action.lock ] || [ -e /tmp/run/tachyon/component-action.lock ] || [ -e /var/run/tachyon/component-actions/action.lock ] || [ -e /tmp/run/tachyon/component-actions/action.lock ]; then
exit 0
fi