Commit 1ab796fa authored by Franziska Hinkelmann's avatar Franziska Hinkelmann Committed by cjihrig
Browse files

src: do not copy on failing setProperty()

In vm, the setter interceptor should not copy a value onto the
sandbox, if setting it on the global object will fail. It will fail if
we are in strict mode and set a value without declaring it.

Fixes: https://github.com/nodejs/node/issues/5344
PR-URL: https://github.com/nodejs/node/pull/7908


Reviewed-By: default avatarAli Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: default avatarBen Noordhuis <info@bnoordhuis.nl>
Reviewed-By: default avatarJames M Snell <jasnell@gmail.com>
Reviewed-By: default avatarColin Ihrig <cjihrig@gmail.com>
parent 27f92efa
Supports Markdown
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