|
From: | Martin Kunz |
Subject: | Re: cell2csv (io package): Higher precision of floating point numbers? |
Date: | Tue, 30 Aug 2016 12:57:17 +0200 |
User-agent: | Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 |
Am 30.08.2016 um 12:16 schrieb
PhilipNienhuis:
IIRC C++ silently extends strings if assignments overflow the current string length. I am not familiar with C++, but these two links
suggest that while 'std::string' buffers are automatically extended, the 'char tmp[20]' used in cell2csv.cc is old C-style and can overflow. Defining the temporary variable as 'char tmp[25]' (or maybe 30 characters long, just to be sure?) seems the right thing to do here. Martin |
[Prev in Thread] | Current Thread | [Next in Thread] |