mirror of
git://projects.qi-hardware.com/xburst-tools.git
synced 2024-11-22 18:12:27 +02:00
qi-strip-trailing-newlines-in-append-file.patch
Signed-off-by: Andy Green <andy@openmoko.com>
This commit is contained in:
parent
5ffd09774d
commit
fbc7e8b244
@ -181,6 +181,7 @@ static void do_params(unsigned initramfs_len,
|
||||
(this_board->get_board_variant)();
|
||||
const char *p;
|
||||
char * cmdline;
|
||||
char * p1;
|
||||
struct tag *params = (struct tag *)this_board->linux_tag_placement;
|
||||
|
||||
/* eat leading white space */
|
||||
@ -228,6 +229,12 @@ static void do_params(unsigned initramfs_len,
|
||||
cmdline += strlen(strcpy(cmdline,
|
||||
commandline_rootfs_append));
|
||||
|
||||
/* deal with any trailing newlines that hitched a ride */
|
||||
|
||||
p1 = cmdline + strlen(cmdline) - 1;
|
||||
while (*p1 == '\n')
|
||||
*p1-- = '\0';
|
||||
|
||||
/*
|
||||
* if he's still holding down the UI_ACTION_SKIPKERNEL key
|
||||
* now we finished loading the kernel, take it to mean he wants
|
||||
|
Loading…
Reference in New Issue
Block a user