From e6a1ebb7c6eb226c28e813f0889c290533e0a8a2 Mon Sep 17 00:00:00 2001 From: giraffedata Date: Mon, 19 Jan 2015 02:34:20 +0000 Subject: Fix bug from earlier today git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@2386 9d0c8265-081b-0410-96cb-a4ca84ce46f8 --- converter/pgm/sbigtopgm.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/converter/pgm/sbigtopgm.c b/converter/pgm/sbigtopgm.c index 308a7d6d..883e3396 100644 --- a/converter/pgm/sbigtopgm.c +++ b/converter/pgm/sbigtopgm.c @@ -178,7 +178,7 @@ readSbigHeader(FILE * const ifP, (unsigned)(cursor - &buffer[0])); } *cp = '\0'; - if (STRSEQ("ST-", cursor)) { + if (strneq(cursor, "ST-", 3)) { char * const ep = strchr(cursor + 3, ' '); if (ep != NULL) { @@ -189,16 +189,16 @@ readSbigHeader(FILE * const ifP, } } looseCanon(cursor); - if (STRSEQ("ST-", cursor)) { + if (strneq(cursor, "ST-", 3)) { sbigHeaderP->isCompressed = (strstr("compressed", cursor) != NULL); gotCompression = true; - } else if (STRSEQ("height=", cursor)) { + } else if (strneq(cursor, "height=", 7)) { sbigHeaderP->rows = atoi(cursor + 7); gotHeight = true; - } else if (STRSEQ("width=", cursor)) { + } else if (strneq(cursor, "width=", 6)) { sbigHeaderP->cols = atoi(cursor + 6); gotWidth = true; - } else if (STRSEQ("sat_level=", cursor)) { + } else if (strneq(cursor, "sat_level=", 10)) { sbigHeaderP->maxval = atoi(cursor + 10); } else if (streq("end", cursor)) { endOfHeader = true; -- cgit 1.4.1