430bf378418e655b06d518a7cd62ae680301af80 |
|
07-May-2015 |
Alistair Strachan <alistair.strachan@imgtec.com> |
Fix switch_root implementation. Add the MS_MOVE of cwd to / and chroot into it. chdir is also called to ensure cwd does not point outside the chroot. The switch_root toy was also blocking any case where NEW_ROOT/init did not exist, even though NEW_INIT was a required parameter and did not have to be '/init'. Change it to handle any NEW_INIT passed as either a relative or absolute path. With this change, the switch_root toy actually works from initramfs.
/external/toybox/toys/other/switch_root.c
|
fec3fd1f8ac1db9ed87b79bd3eb5e38aa835e881 |
|
26-Jul-2014 |
Rob Landley <rob@landley.net> |
Move DIRTREE_COMEAGAIN second callback up to when the filehandle is still open, and add dir->again variable to distinguish second call instead of checking for -1 filehandle.
/external/toybox/toys/other/switch_root.c
|
7aa651a6a4496d848f86de9b1e6b3a003256a01f |
|
14-Nov-2012 |
Rob Landley <rob@landley.net> |
Reindent to two spaces per level. Remove vi: directives that haven't worked right in years (ubuntu broke its' vim implementation). Remove trailing spaces. Add/remove blank lines. Re-wordwrap in places. Update documentation with new coding style. The actual code should be the same afterward, this is just cosmetic refactoring.
/external/toybox/toys/other/switch_root.c
|
c0e56edaf256adb6c60c5a052525a1ffbb927901 |
|
08-Oct-2012 |
Rob Landley <rob@landley.net> |
New build infrastructure to generate FLAG_ macros and TT alias, #define FOR_commandname before #including toys.h to trigger it. Rename DEFINE_GLOBALS() to just GLOBALS() (because I could never remember if it was DECLARE_GLOBALS). Convert existing commands to use new infrastructure, and replace optflag constants with FLAG_ macros where appropriate.
/external/toybox/toys/other/switch_root.c
|
787eac5f1dac70ee4a6ac79699f6da87b8fd6ee6 |
|
08-Sep-2012 |
Rob Landley <rob@landley.net> |
Add switch_root and fix infrastructure to understand name "switch_root".
/external/toybox/toys/other/switch_root.c
|