aboutsummaryrefslogtreecommitdiff
path: root/coreutils/test.c
diff options
context:
space:
mode:
Diffstat (limited to 'coreutils/test.c')
-rw-r--r--coreutils/test.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/coreutils/test.c b/coreutils/test.c
index 3115ce6e7..0b9322316 100644
--- a/coreutils/test.c
+++ b/coreutils/test.c
@@ -393,7 +393,7 @@ static number_t getn(const char *s)
393 if (errno != 0) 393 if (errno != 0)
394 syntax(s, "out of range"); 394 syntax(s, "out of range");
395 395
396 if (*(skip_whitespace(p))) 396 if (p == s || *(skip_whitespace(p)) != '\0')
397 syntax(s, "bad number"); 397 syntax(s, "bad number");
398 398
399 return r; 399 return r;