[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Possible bug when field-separator used
From: |
Erik Auerswald |
Subject: |
Re: Possible bug when field-separator used |
Date: |
Sat, 16 Dec 2023 18:26:39 +0100 |
Hi all,
On Tue, Dec 05, 2023 at 12:42:22PM +0100, Erik Auerswald wrote:
> On Mon, Dec 04, 2023 at 01:55:14PM +0100, Erik Auerswald wrote:
> > [...]
> > We could also always use the code inside the "#ifdef HAVE_BROKEN_STRTOLD"
> > all the time, or use something alike as a fallback in case of the
> > "endptr!=(str+slen)" error condition after strtold().
>
> I think that I should have time to look into this in about two weeks.
I have just pushed a fix for this bug based on the second idea above:
first try to use strtold() just as before, but if this reads over the
field delimiter, copy the field contents to a NUL-delimited buffer and
use strtold() on that buffer:
https://git.savannah.gnu.org/gitweb/?p=datamash.git;a=commitdiff;h=52f1c59ef8a57646048f1398b02bd36fae57b343
Best regards,
Erik