No subject
Mon Nov 10 21:43:42 UTC 2008
Exit status:
0 if all variables specified were found
1 if at least one specified variable was not found
2 if a write error occurred
If coreutils doesn't find a particular environment variable (given as
command-line arg), then it will return exitcode 1, whereas busybox simply
still returns 0, which goes against the spec above.
Coreutils:
$ printenv blahblah
$ echo $?
1
(environment variable 'blahblah' not found, so returns 1)
$ printenv _ blahblah
/usr/bin/printenv
$ echo $?
1
(Note that the _ variable returns the name of the currently-executing
program, so it is found, but 'blahblah' is still not found, so still
returns 1.)
Busybox:
$ ./busybox printenv blahblah
$ echo $?
0
pgbovine at hexapod ~/busybox
$ ./busybox printenv _ blahblah
./busybox
$ echo $?
0
Exits with 0 even though 'blahblah' was not found.
======================================================================
----------------------------------------------------------------------
vda - 11-11-08 15:00
----------------------------------------------------------------------
Fixed in svn, thanks.
Issue History
Date Modified Username Field Change
======================================================================
11-11-08 13:50 pgbovine New Issue
11-11-08 13:50 pgbovine Status new => assigned
11-11-08 13:50 pgbovine Assigned To => BusyBox
11-11-08 15:00 vda Status assigned => closed
11-11-08 15:00 vda Note Added: 0015494
======================================================================
More information about the busybox-cvs
mailing list