X-Git-Url: https://git.armaanb.net/?p=sic.git;a=blobdiff_plain;f=util.c;h=25678120422eea5ec0782e9040fdd5ad24b9ff45;hp=bdba7188b246412d158398b30e6a829c5442940f;hb=df4c0611366bf361fa263fbc57009cbe68456855;hpb=ec293427a0cc2ef7f561a60347ce940d567efb72 diff --git a/util.c b/util.c index bdba718..2567812 100644 --- a/util.c +++ b/util.c @@ -61,7 +61,7 @@ trim(char *s) { char *e; e = s + strlen(s) - 1; - while(isspace(*e) && e > s) + while(e > s && isspace(*e)) e--; *(e + 1) = '\0'; }