From: Jim Meyering Date: Mon, 6 Aug 2001 09:50:05 +0000 (+0000) Subject: finally make it work X-Git-Tag: TEXTUTILS-2_0_15~486 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=11b02c5e135c32fa8dbae463b50ed8db10e103ad;p=platform%2Fupstream%2Fcoreutils.git finally make it work --- diff --git a/tests/priv-check b/tests/priv-check index 786a4a591..4b95f860f 100644 --- a/tests/priv-check +++ b/tests/priv-check @@ -12,7 +12,17 @@ priv_check_temp=priv-check.$$ touch $priv_check_temp || framework_failure=1 chmod a-w $priv_check_temp || framework_failure=1 -(echo foo >> $priv_check_temp) >/dev/null 2>&1 || { +(echo foo >> $priv_check_temp) >/dev/null 2>&1 +overwrite_status=$? +give_msg=no +case $1:$overwrite_status in + require-root:0) ;; + require-root:*) give_msg=yes ;; + require-non-root:0) give_msg=yes ;; + require-non-root:*) ;; +esac + +test $give_msg = yes && { cat <