summaryrefslogtreecommitdiffstats
path: root/src/lex.c
diff options
context:
space:
mode:
authorIku <iku@yokattana.com>2017-02-09 09:35:56 +0100
committerIku <iku@yokattana.com>2017-02-09 09:42:52 +0100
commitfa629a841d2113f01605030acebf8e4a3f656a62 (patch)
treef3fb8de5fde6bb440dc3466cbfbbc436b0d62d73 /src/lex.c
parent474e05785ad4ecb3b40626093c51e9f69acf9000 (diff)
Replace obsolete finite() calls with isfinite()
Addressing https://github.com/andmarti1424/sc-im/issues/120 As mentioned in Linux's finite(2): Note that these functions are obsolete. This commit requires _GNU_SOURCE, or another feature level supporting isfinite() to be defined.
Diffstat (limited to 'src/lex.c')
-rw-r--r--src/lex.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lex.c b/src/lex.c
index 1220f4e..fc63bd4 100644
--- a/src/lex.c
+++ b/src/lex.c
@@ -229,7 +229,7 @@ int yylex() {
if ((!dateflag && *p=='.') || ret == FNUMBER) {
ret = FNUMBER;
yylval.fval = strtod(nstart, &p);
- if (!finite(yylval.fval))
+ if (!isfinite(yylval.fval))
ret = K_ERR;
else
decimal = TRUE;