Commit 69afb098 authored by Frédéric Delanoy's avatar Frédéric Delanoy Committed by Alexandre Julliard

jscript: Don't copy more than needed in parse_string_literal.

parent 6e1ad65d
......@@ -361,7 +361,7 @@ static int parse_string_literal(parser_ctx_t *ctx, const WCHAR **ret, WCHAR endc
len = ctx->ptr-ptr;
*ret = wstr = parser_alloc(ctx, (len+1)*sizeof(WCHAR));
memcpy(wstr, ptr, (len+1)*sizeof(WCHAR));
memcpy(wstr, ptr, len*sizeof(WCHAR));
wstr[len] = 0;
ctx->ptr++;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment