From d1260f4e4d279cab881c6df0183135d9cf40be58 Mon Sep 17 00:00:00 2001 From: rlar Date: Wed, 31 Dec 2014 15:59:51 +0100 Subject: [PATCH] inpcom.c, cleanup inp_remove_ws(), #2/4, dup some code down into if-then-else --- src/frontend/inpcom.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/frontend/inpcom.c b/src/frontend/inpcom.c index e41e2f14a..4a31bebb2 100644 --- a/src/frontend/inpcom.c +++ b/src/frontend/inpcom.c @@ -2210,8 +2210,8 @@ inp_remove_ws(char *s) if (*s == '}') is_expression = FALSE; - *d++ = *s; if (*s == '=' || (is_expression && (is_arith_char(*s) || *s == ','))) { + *d++ = *s; s = skip_ws(s + 1); if (*s == '\0') @@ -2222,6 +2222,8 @@ inp_remove_ws(char *s) if (*s == '}') is_expression = FALSE; + *d++ = *s; + } else { *d++ = *s; } s++;