Also re-implement WorkerOrWorkletScriptController::forbidExecution() and isExecutionForbidden() using the VM's notion of the flag. rdar://77548608
Created attachment 427797 [details] propose patch.
Comment on attachment 427797 [details] propose patch. View in context: https://bugs.webkit.org/attachment.cgi?id=427797&action=review r=me with a suggested change. > Source/JavaScriptCore/runtime/VM.h:345 > + void setExecutionForbidden(bool value) { m_executionForbidden = value; } Seem like we only want to go from "execution allowed", e.g. m_executionForbidden == false, to "execution forbidden", e.g. m_executionForbidden == true. I suggest we eliminate the argument to setExecutionForbidden() and have it always set m_executionForbidden to true.
(In reply to Michael Saboff from comment #2) > Comment on attachment 427797 [details] > propose patch. > > View in context: > https://bugs.webkit.org/attachment.cgi?id=427797&action=review > > r=me with a suggested change. > > > Source/JavaScriptCore/runtime/VM.h:345 > > + void setExecutionForbidden(bool value) { m_executionForbidden = value; } > > Seem like we only want to go from "execution allowed", e.g. > m_executionForbidden == false, to "execution forbidden", e.g. > m_executionForbidden == true. I suggest we eliminate the argument to > setExecutionForbidden() and have it always set m_executionForbidden to true. I agree. That's probably the better approach until we find evidence to the contrary.
Thanks for the review. I've made the suggested change. Landed in r277094: <http://trac.webkit.org/r277094>.