mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 516458 followup: adding the terminator to improve accuracy for short strings, rs=brendan
This commit is contained in:
parent
127f3afdb7
commit
6b652df63e
@ -2622,7 +2622,7 @@ JS_NewExternalString(JSContext *cx, jschar *chars, size_t length, intN type)
|
||||
if (!str)
|
||||
return NULL;
|
||||
str->initFlat(chars, length);
|
||||
cx->updateMallocCounter(length * sizeof(jschar));
|
||||
cx->updateMallocCounter((length + 1) * sizeof(jschar));
|
||||
return str;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user