Change 0 to NULL Byte

Change-Id: I16b47f8dbf64e8dffb550b5a89321f920604ef7a
This commit is contained in:
Alice Chu 2012-10-30 16:27:00 -07:00
parent 47cd396b11
commit f6647eb9f4

View file

@ -851,11 +851,11 @@ static void parse() {
log_info("Got line %d\n", lineno);
len = strlen(line_buf);
if (line_buf[len - 1] == '\n')
line_buf[len - 1] = 0;
line_buf[len - 1] = '\0';
p = line_buf;
while (isspace(*p))
p++;
if (*p == '#' || *p == 0)
if (*p == '#' || *p == '\0')
continue;
token = strtok_r(p, " \t", &saveptr);