From a3546d0a323b3ebce167d3b1d42ac8d10c5280d2 Mon Sep 17 00:00:00 2001 From: Laurent Mazet Date: Tue, 26 Dec 2023 03:51:13 +0100 Subject: [PATCH] correct convertion from non decimal base --- parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/parser.c b/parser.c index 44152a9..7880acf 100644 --- a/parser.c +++ b/parser.c @@ -290,7 +290,7 @@ element_t *parser (char *str, char **next, int prio) VERBOSE (DEBUG, fprintf (stdout, "start processing value\n")); char *pt; - double value = (get_ibase () == 10) ? strtod (str, &pt) : strtoul (str, &pt, get_ibase ()); + double value = (get_ibase () == 10) ? strtod (str, &pt) : strtol (str, &pt, get_ibase ()); VERBOSE (INFO, fprintf (stdout, "Value: %f\n", value)); if (str != pt) { if ((root == NULL) || (root->prio == 6)) { -- 2.30.2