From fef66999f849771f087869f715e1adb94580cc04 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Mon, 6 Oct 2014 05:55:35 +0000 Subject: [PATCH] base-files: make postinst script run inside a subshell Signed-off-by: John Crispin git-svn-id: svn://svn.openwrt.org/openwrt/trunk@42800 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- package/base-files/files/lib/functions.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package/base-files/files/lib/functions.sh b/package/base-files/files/lib/functions.sh index fafb7a340f..7f148223f5 100755 --- a/package/base-files/files/lib/functions.sh +++ b/package/base-files/files/lib/functions.sh @@ -173,7 +173,7 @@ default_prerm() { default_postinst() { local name rusers name=$(echo $(basename $1) | cut -d. -f1) - [ -f ${IPKG_INSTROOT}/usr/lib/opkg/info/${name}.postinst-pkg ] && . ${IPKG_INSTROOT}/usr/lib/opkg/info/${name}.postinst-pkg + [ -f ${IPKG_INSTROOT}/usr/lib/opkg/info/${name}.postinst-pkg ] && ( . ${IPKG_INSTROOT}/usr/lib/opkg/info/${name}.postinst-pkg ) rusers=$(grep "Require-User:" ${IPKG_INSTROOT}/usr/lib/opkg/info/${name}.control) [ -n "$rusers" ] && { local user group -- 2.11.0