fix: reserve was not called correctly

This commit is contained in:
Evan Tschannen 2018-09-10 15:20:41 -07:00
parent 02d7b02036
commit fb0d1d12a3
1 changed files with 1 additions and 1 deletions

View File

@ -193,7 +193,7 @@ protected:
void writeCoercedAsciiNumber(const char *s, int len) {
VString &val = jsonText.back();
val.reserve(arena, len + 3);
val.reserve(arena, val.size() + len + 3);
int written = coerceAsciiNumberToJSON(s, len, val.end());
if(written > 0) {
val.extendUnsafeNoReallocNoInit(written);