projects
/
gnulib.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
(OtherTable): Interpret `next' as 1 (not 2) units.
[gnulib.git]
/
lib
/
xstrtol.c
diff --git
a/lib/xstrtol.c
b/lib/xstrtol.c
index
fea6c48
..
ad2bcdb
100644
(file)
--- a/
lib/xstrtol.c
+++ b/
lib/xstrtol.c
@@
-91,15
+91,14
@@
__xstrtol (s, ptr, base, val, valid_suffixes)
return LONGINT_OVERFLOW;
if (*p == s)
return LONGINT_INVALID;
return LONGINT_OVERFLOW;
if (*p == s)
return LONGINT_INVALID;
+
+ /* Let valid_suffixes == NULL mean `allow any suffix'. */
+ /* FIXME: update all callers except the one in tail.c changing
+ last parameter NULL to `""'. */
if (!valid_suffixes)
{
if (!valid_suffixes)
{
- if (**p == '\0')
- {
- *val = tmp;
- return LONGINT_OK;
- }
- else
- return LONGINT_INVALID_SUFFIX_CHAR;
+ *val = tmp;
+ return LONGINT_OK;
}
if (**p != '\0')
}
if (**p != '\0')