[BusyBox 0001425]: switch_root steals args meant for the new init
bugs at busybox.net
bugs at busybox.net
Mon Jul 9 06:18:42 UTC 2007
The following issue has been SUBMITTED.
======================================================================
http://busybox.net/bugs/view.php?id=1425
======================================================================
Reported By: owen
Assigned To: BusyBox
======================================================================
Project: BusyBox
Issue ID: 1425
Category: Other
Reproducibility: always
Severity: minor
Priority: normal
Status: assigned
======================================================================
Date Submitted: 07-08-2007 23:18 PDT
Last Modified: 07-08-2007 23:18 PDT
======================================================================
Summary: switch_root steals args meant for the new init
Description:
The format for a call to switch_root is:
switch_root [-c /dev/console] NEW_ROOT NEW_INIT [ARGUMENTS_TO_INIT]
The init man page includes:
-z xxx
The argument to -z is ignored. You can use this to expand
the command line a bit, so that it takes some more space on the stack.
Init can then manipulate the command line so that ps(1) shows the
current runlevel.
But, the getopt32() function notices the flag at the end, and bails with a
"switch_root: illegal option -- z"
I'm not a C guru; is there a way to make getopt32() stop parsing at the
first non-option? Or maybe at least exclude the last one?
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
07-08-07 23:18 owen New Issue
07-08-07 23:18 owen Status new => assigned
07-08-07 23:18 owen Assigned To => BusyBox
======================================================================
More information about the busybox-cvs
mailing list