]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Fix compile error in install-sh - I forgot that "function" is a bashism.
authormike <mike@7a7537e8-13f0-0310-91df-b6672ffda945>
Mon, 21 May 2012 15:33:01 +0000 (15:33 +0000)
committermike <mike@7a7537e8-13f0-0310-91df-b6672ffda945>
Mon, 21 May 2012 15:33:01 +0000 (15:33 +0000)
Also block running tests as root.

git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@10487 7a7537e8-13f0-0310-91df-b6672ffda945

install-sh
test/run-stp-tests.sh

index bd8f459c75dec8f018235c3b3554823cb13ff225..41d944e3e29fe1714597850a849243af067b3a91 100755 (executable)
@@ -61,7 +61,7 @@ src=""
 dst=""
 dir_arg=""
 
-function gzipcp {
+gzipcp() {
        # gzipcp from to
        $gzipprog -9 <"$1" >"$2"
 }
index 6130c95514aa66efdee363bbee536c432ccf1a0d..473ab1c20023e6e637bae76f757e17827888e2d0 100755 (executable)
 
 argcount=$#
 
+#
+# Don't allow "make check" or "make test" to be run by root...
+#
+
+if test "x`id -u`" = x0; then
+       echo Please run this as a normal user. Not supported when run as root.
+       exit 1
+fi
+
+#
+# Force the permissions of the files we create...
+#
+
+umask 2
+
 #
 # Make the IPP test program...
 #