Changeset 189295 in webkit
- Timestamp:
- Sep 3, 2015 3:28:55 PM (9 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r189293 r189295 1 2015-09-03 Brian Burg <bburg@apple.com> 2 3 Web Inspector: should crash on purpose if InjectedScriptSource.js is unparseable 4 https://bugs.webkit.org/show_bug.cgi?id=148750 5 6 Reviewed by Timothy Hatcher. 7 8 If an injected script cannot be parsed or executed without exception, we should abort as 9 soon as possible. This patch adds a release assertion after creating the injected 10 script and dumps the bad injected script's source as it was embedded into the binary. 11 12 * inspector/InjectedScriptManager.cpp: 13 (Inspector::InjectedScriptManager::injectedScriptFor): 14 1 15 2015-09-03 Basile Clement <basile_clement@apple.com> and Michael Saboff <msaboff@apple.com> 2 16 -
trunk/Source/JavaScriptCore/inspector/InjectedScriptManager.cpp
r185608 r189295 178 178 int id = injectedScriptIdFor(inspectedExecState); 179 179 Deprecated::ScriptObject injectedScriptObject = createInjectedScript(injectedScriptSource(), inspectedExecState, id); 180 if (injectedScriptObject.scriptState() != inspectedExecState) { 181 WTFLogAlways("Failed to parse/execute InjectedScriptSource.js!"); 182 WTFLogAlways("%s\n", injectedScriptSource().ascii().data()); 183 RELEASE_ASSERT_NOT_REACHED(); 184 } 185 180 186 InjectedScript result(injectedScriptObject, &m_environment); 181 187 m_idToInjectedScript.set(id, result);
Note: See TracChangeset
for help on using the changeset viewer.