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:
committed by
Wolfgang Denk
parent
ce2d4c9532
commit
4d91a6ecab
@@ -16,6 +16,7 @@
|
||||
|
||||
#include <common.h>
|
||||
#include <exports.h>
|
||||
#include <linux/ctype.h>
|
||||
#include "../drivers/net/smc911x.h"
|
||||
|
||||
/**
|
||||
@@ -128,7 +129,7 @@ static int write_eeprom_reg(struct eth_device *dev, u8 value, u8 reg)
|
||||
*/
|
||||
static char *skip_space(char *buf)
|
||||
{
|
||||
while (buf[0] == ' ' || buf[0] == '\t')
|
||||
while (isblank(buf[0]))
|
||||
++buf;
|
||||
return buf;
|
||||
}
|
||||
@@ -357,7 +358,7 @@ int smc911x_eeprom(int argc, char * const argv[])
|
||||
continue;
|
||||
|
||||
/* Only accept 1 letter commands */
|
||||
if (line[0] && line[1] && line[1] != ' ' && line[1] != '\t')
|
||||
if (line[0] && line[1] && !isblank(line[1]))
|
||||
goto unknown_cmd;
|
||||
|
||||
/* Now parse the command */
|
||||
|
Reference in New Issue
Block a user