diff options
author | Jim Meyering <jim@meyering.net> | 2004-03-10 10:44:31 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2004-03-10 10:44:31 +0000 |
commit | aa18f80de6731593fb309ede9f0e18b08bde7352 (patch) | |
tree | c153ab021df3878104b81e1c6832699fc786c0b0 | |
parent | 97f63d336f069f86ab108cd2ebfa5c3dff907809 (diff) | |
download | coreutils-aa18f80de6731593fb309ede9f0e18b08bde7352.tar.xz |
`join -1 x' would give a misleading diagnostic
(string_to_join_field): Report that a non-numeric field
number is invalid, rather than `so large that it is not representable'.
-rw-r--r-- | src/join.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/join.c b/src/join.c index db875ec32..2716ae339 100644 --- a/src/join.c +++ b/src/join.c @@ -642,7 +642,7 @@ string_to_join_field (char const *str, char const *err_msg_fmt) uintmax_t val; strtol_error s_err = xstrtoumax (str, NULL, 10, &val, ""); - if (s_err == LONGINT_OVERFLOW || SIZE_MAX < val) + if (s_err == LONGINT_OVERFLOW || (s_err == LONGINT_OK && SIZE_MAX < val)) { error (EXIT_FAILURE, 0, _("value %s is so large that it is not representable"), |