projects
/
linux-2.6-microblaze.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' of ssh://rsync.linux-nfs.org/home/trondmy/www_sites/rsync.linux...
[linux-2.6-microblaze.git]
/
kernel
/
params.c
diff --git
a/kernel/params.c
b/kernel/params.c
index
fbf1732
..
1a8614b
100644
(file)
--- a/
kernel/params.c
+++ b/
kernel/params.c
@@
-80,8
+80,6
@@
static char *next_arg(char *args, char **param, char **val)
int in_quote = 0, quoted = 0;
char *next;
int in_quote = 0, quoted = 0;
char *next;
- /* Chew any extra spaces */
- while (*args == ' ') args++;
if (*args == '"') {
args++;
in_quote = 1;
if (*args == '"') {
args++;
in_quote = 1;
@@
-121,6
+119,10
@@
static char *next_arg(char *args, char **param, char **val)
next = args + i + 1;
} else
next = args + i;
next = args + i + 1;
} else
next = args + i;
+
+ /* Chew up trailing spaces. */
+ while (*next == ' ')
+ next++;
return next;
}
return next;
}
@@
-135,6
+137,10
@@
int parse_args(const char *name,
DEBUGP("Parsing ARGS: %s\n", args);
DEBUGP("Parsing ARGS: %s\n", args);
+ /* Chew leading spaces */
+ while (*args == ' ')
+ args++;
+
while (*args) {
int ret;
while (*args) {
int ret;