Changeset 209149 in webkit
- Timestamp:
- Nov 30, 2016 1:13:42 PM (7 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r209145 r209149 1 2016-11-30 Mark Lam <mark.lam@apple.com> 2 3 Proxy is not allowed in the global prototype chain. 4 https://bugs.webkit.org/show_bug.cgi?id=165205 5 6 Reviewed by Geoffrey Garen. 7 8 * js/dom/proxy-is-not-allowed-in-global-prototype-chain-expected.txt: Added. 9 * js/dom/proxy-is-not-allowed-in-global-prototype-chain.html: Added. 10 1 11 2016-11-30 Brent Fulgham <bfulgham@apple.com> 2 12 -
trunk/Source/JavaScriptCore/ChangeLog
r209146 r209149 1 2016-11-30 Mark Lam <mark.lam@apple.com> 2 3 Proxy is not allowed in the global prototype chain. 4 https://bugs.webkit.org/show_bug.cgi?id=165205 5 6 Reviewed by Geoffrey Garen. 7 8 * runtime/ProgramExecutable.cpp: 9 (JSC::ProgramExecutable::initializeGlobalProperties): 10 - We'll now throw a TypeError if we detect a Proxy in the global prototype chain. 11 1 12 2016-11-30 Commit Queue <commit-queue@webkit.org> 2 13 -
trunk/Source/JavaScriptCore/runtime/ProgramExecutable.cpp
r208950 r209149 80 80 ASSERT(&globalObject->vm() == &vm); 81 81 82 JSValue nextPrototype = globalObject->getPrototypeDirect(); 83 while (nextPrototype && nextPrototype.isObject()) { 84 if (UNLIKELY(asObject(nextPrototype)->type() == ProxyObjectType)) { 85 ExecState* exec = globalObject->globalExec(); 86 return createTypeError(exec, ASCIILiteral("Proxy is not allowed in the global prototype chain.")); 87 } 88 nextPrototype = asObject(nextPrototype)->getPrototypeDirect(); 89 } 90 82 91 JSObject* exception = nullptr; 83 92 UnlinkedProgramCodeBlock* unlinkedCodeBlock = globalObject->createProgramCodeBlock(callFrame, this, &exception); … … 178 187 } 179 188 } 180 return 0;189 return nullptr; 181 190 } 182 191
Note: See TracChangeset
for help on using the changeset viewer.