git: aa588213d8f5 - main - ministat: revert "parse comma used as decimal delimiter"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 20 Jul 2026 18:40:45 UTC
The branch main has been updated by glebius:
URL: https://cgit.FreeBSD.org/src/commit/?id=aa588213d8f54803fc0b6b09d34f20fb30e57896
commit aa588213d8f54803fc0b6b09d34f20fb30e57896
Author: Gleb Smirnoff <glebius@FreeBSD.org>
AuthorDate: 2026-07-20 18:38:33 +0000
Commit: Gleb Smirnoff <glebius@FreeBSD.org>
CommitDate: 2026-07-20 18:40:28 +0000
ministat: revert "parse comma used as decimal delimiter"
This partially reverts commit 77a201b1705dbd97ea9ebe5b25b1d4ddac8a7d38.
Requested by: des, fuz
---
usr.bin/ministat/ministat.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/usr.bin/ministat/ministat.c b/usr.bin/ministat/ministat.c
index bb2b7e32ea0b..bc2f49fb8536 100644
--- a/usr.bin/ministat/ministat.c
+++ b/usr.bin/ministat/ministat.c
@@ -483,7 +483,7 @@ dbl_cmp(const void *a, const void *b)
static struct dataset *
ReadSet(FILE *f, const char *n, int column, const char *delim)
{
- char buf[BUFSIZ], *p, *t, *comma;
+ char buf[BUFSIZ], *p, *t;
struct dataset *s;
double d;
int line;
@@ -507,8 +507,7 @@ ReadSet(FILE *f, const char *n, int column, const char *delim)
}
if (t == NULL || *t == '#')
continue;
- if ((comma = strchr(t, ',')) != NULL)
- *comma = '.';
+
d = strtod(t, &p);
if (p != NULL && *p != '\0')
errx(2, "Invalid data \"%s\" on line %d in %s",