1
0
mirror of https://xff.cz/git/u-boot/ synced 2025-09-01 08:42:12 +02:00

Replace space and tab checks with isblank

These are various places I found that checked for conditions equivalent
to isblank.

Signed-off-by: Jason Hobbs <jason.hobbs@calxeda.com>
This commit is contained in:
Jason Hobbs
2011-08-23 11:06:54 +00:00
committed by Wolfgang Denk
parent ce2d4c9532
commit 4d91a6ecab
6 changed files with 23 additions and 16 deletions

View File

@@ -40,6 +40,7 @@
#endif
#include <post.h>
#include <linux/ctype.h>
#if defined(CONFIG_SILENT_CONSOLE) || defined(CONFIG_POST) || defined(CONFIG_CMDLINE_EDITING)
DECLARE_GLOBAL_DATA_PTR;
@@ -1097,7 +1098,7 @@ int parse_line (char *line, char *argv[])
while (nargs < CONFIG_SYS_MAXARGS) {
/* skip any white space */
while ((*line == ' ') || (*line == '\t'))
while (isblank(*line))
++line;
if (*line == '\0') { /* end of line, no more args */
@@ -1111,7 +1112,7 @@ int parse_line (char *line, char *argv[])
argv[nargs++] = line; /* begin of argument string */
/* find end of string */
while (*line && (*line != ' ') && (*line != '\t'))
while (*line && !isblank(*line))
++line;
if (*line == '\0') { /* end of line, no more args */