mirror of
https://github.com/open-source-parsers/jsoncpp.git
synced 2025-04-06 02:45:02 +02:00
Merge pull request #609 from antonindrawan/QNX_Fix
Fix QNX build: QNX defines sprintf under the std namespace.
This commit is contained in:
commit
d7347a2623
@ -143,7 +143,7 @@ JSONCPP_STRING valueToString(double value, bool useSpecialFloats, unsigned int p
|
||||
int len = -1;
|
||||
|
||||
char formatString[6];
|
||||
sprintf(formatString, "%%.%dg", precision);
|
||||
snprintf(formatString, sizeof(formatString), "%%.%dg", precision);
|
||||
|
||||
// Print into the buffer. We need not request the alternative representation
|
||||
// that always has a decimal point because JSON doesn't distingish the
|
||||
|
Loading…
x
Reference in New Issue
Block a user