[BusyBox 0001047]: ash uses the variables in a way not visible to printenv
bugs at busybox.net
bugs at busybox.net
Thu Feb 14 16:35:00 UTC 2008
A NOTE has been added to this issue.
======================================================================
http://busybox.net/bugs/view.php?id=1047
======================================================================
Reported By: walter
Assigned To: BusyBox
======================================================================
Project: BusyBox
Issue ID: 1047
Category: Standards Compliance
Reproducibility: always
Severity: minor
Priority: normal
Status: assigned
======================================================================
Date Submitted: 09-24-2006 05:54 PDT
Last Modified: 02-14-2008 08:35 PST
======================================================================
Summary: ash uses the variables in a way not visible to
printenv
Description:
clearly ash uses the variables in a way not visible to printenv
and different to sh. the example shows that only if variables are
exported
showup with printenv.
#/* test program */
f()
{
printenv FOO
}
echo "set + function"
FOO=test f
echo "printenv"
printenv FOO
echo "exported + printenv"
export FOO=exported
printenv FOO
======================================================================
----------------------------------------------------------------------
vda - 02-14-08 08:35
----------------------------------------------------------------------
printenv has nothing to do with it.
Smaller testcase:
f() { true; }
echo "case 1"
FOO=test /bin/true
env | grep FOO
echo "case 2"
FOO=test f
env | grep FOO
Surprisingly, with bash 3.2 in case FOO actually remains set in
environment, as if it was an exported variable! This is strange and may be
a bash bug.
$ sh testcase2
case 1
case 2
FOO=test
$ ./busybox ash testcase2
case 1
case 2
Issue History
Date Modified Username Field Change
======================================================================
09-24-06 05:54 walter New Issue
09-24-06 05:54 walter Status new => assigned
09-24-06 05:54 walter Assigned To => BusyBox
02-14-08 08:35 vda Note Added: 0004714
======================================================================
More information about the busybox-cvs
mailing list