Title: [87145] trunk
- Revision
- 87145
- Author
- yu...@chromium.org
- Date
- 2011-05-24 05:38:13 -0700 (Tue, 24 May 2011)
Log Message
2011-05-23 Yury Semikhatsky <yu...@chromium.org>
Reviewed by Adam Barth.
Chromium DevTools: Tab crashes with "Aw, snap!" on entering "(new Image())." in console
https://bugs.webkit.org/show_bug.cgi?id=61194
* inspector/console/console-eval-syntax-error-expected.txt: Added.
* inspector/console/console-eval-syntax-error.html: Added.
* platform/chromium/inspector/console/console-eval-syntax-error-expected.txt: Added.
2011-05-23 Yury Semikhatsky <yu...@chromium.org>
Reviewed by Adam Barth.
Chromium DevTools: Tab crashes with "Aw, snap!" on entering "(new Image())." in console
https://bugs.webkit.org/show_bug.cgi?id=61194
Test: inspector/console/console-eval-syntax-error.html
* bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
(WebCore::V8InjectedScriptHost::evaluateCallback): return immediately in case of syntax error
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (87144 => 87145)
--- trunk/LayoutTests/ChangeLog 2011-05-24 11:22:44 UTC (rev 87144)
+++ trunk/LayoutTests/ChangeLog 2011-05-24 12:38:13 UTC (rev 87145)
@@ -1,3 +1,14 @@
+2011-05-23 Yury Semikhatsky <yu...@chromium.org>
+
+ Reviewed by Adam Barth.
+
+ Chromium DevTools: Tab crashes with "Aw, snap!" on entering "(new Image())." in console
+ https://bugs.webkit.org/show_bug.cgi?id=61194
+
+ * inspector/console/console-eval-syntax-error-expected.txt: Added.
+ * inspector/console/console-eval-syntax-error.html: Added.
+ * platform/chromium/inspector/console/console-eval-syntax-error-expected.txt: Added.
+
2011-05-24 Gabor Loki <l...@webkit.org>
Rubber-stamped by Csaba Osztrogonác.
Added: trunk/LayoutTests/inspector/console/console-eval-syntax-error-expected.txt (0 => 87145)
--- trunk/LayoutTests/inspector/console/console-eval-syntax-error-expected.txt (rev 0)
+++ trunk/LayoutTests/inspector/console/console-eval-syntax-error-expected.txt 2011-05-24 12:38:13 UTC (rev 87145)
@@ -0,0 +1,5 @@
+Tests that evaluating an _expression_ with a syntax error in the console won't crash the browser. Bug 61194.
+
+foo().
+Error
+
Property changes on: trunk/LayoutTests/inspector/console/console-eval-syntax-error-expected.txt
___________________________________________________________________
Added: svn:eol-style
Added: trunk/LayoutTests/inspector/console/console-eval-syntax-error.html (0 => 87145)
--- trunk/LayoutTests/inspector/console/console-eval-syntax-error.html (rev 0)
+++ trunk/LayoutTests/inspector/console/console-eval-syntax-error.html 2011-05-24 12:38:13 UTC (rev 87145)
@@ -0,0 +1,25 @@
+<html>
+<head>
+<script src=""
+<script src=""
+<script>
+function test()
+{
+ InspectorTest.evaluateInConsole("foo().", step1);
+
+ function step1()
+ {
+ InspectorTest.dumpConsoleMessages();
+ InspectorTest.completeTest();
+ }
+}
+
+</script>
+</head>
+<body _onload_="runTest()">
+<p>
+Tests that evaluating an _expression_ with a syntax error in the console won't crash the browser.
+<a href="" 61194.</a>
+</p>
+</body>
+</html>
Property changes on: trunk/LayoutTests/inspector/console/console-eval-syntax-error.html
___________________________________________________________________
Added: svn:eol-style
Added: trunk/LayoutTests/platform/chromium/inspector/console/console-eval-syntax-error-expected.txt (0 => 87145)
--- trunk/LayoutTests/platform/chromium/inspector/console/console-eval-syntax-error-expected.txt (rev 0)
+++ trunk/LayoutTests/platform/chromium/inspector/console/console-eval-syntax-error-expected.txt 2011-05-24 12:38:13 UTC (rev 87145)
@@ -0,0 +1,5 @@
+Tests that evaluating an _expression_ with a syntax error in the console won't crash the browser. Bug 61194.
+
+foo().
+SyntaxError
+
Property changes on: trunk/LayoutTests/platform/chromium/inspector/console/console-eval-syntax-error-expected.txt
___________________________________________________________________
Added: svn:eol-style
Modified: trunk/Source/WebCore/ChangeLog (87144 => 87145)
--- trunk/Source/WebCore/ChangeLog 2011-05-24 11:22:44 UTC (rev 87144)
+++ trunk/Source/WebCore/ChangeLog 2011-05-24 12:38:13 UTC (rev 87145)
@@ -1,3 +1,15 @@
+2011-05-23 Yury Semikhatsky <yu...@chromium.org>
+
+ Reviewed by Adam Barth.
+
+ Chromium DevTools: Tab crashes with "Aw, snap!" on entering "(new Image())." in console
+ https://bugs.webkit.org/show_bug.cgi?id=61194
+
+ Test: inspector/console/console-eval-syntax-error.html
+
+ * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
+ (WebCore::V8InjectedScriptHost::evaluateCallback): return immediately in case of syntax error
+
2011-04-13 Steve Block <stevebl...@google.com>
Reviewed by Eric Seidel.
Modified: trunk/Source/WebCore/bindings/v8/custom/V8InjectedScriptHostCustom.cpp (87144 => 87145)
--- trunk/Source/WebCore/bindings/v8/custom/V8InjectedScriptHostCustom.cpp 2011-05-24 11:22:44 UTC (rev 87144)
+++ trunk/Source/WebCore/bindings/v8/custom/V8InjectedScriptHostCustom.cpp 2011-05-24 12:38:13 UTC (rev 87145)
@@ -76,6 +76,8 @@
return v8::ThrowException(v8::Exception::Error(v8::String::New("The argument must be a string.")));
v8::Handle<v8::Script> script = v8::Script::Compile(_expression_);
+ if (script.IsEmpty()) // Return immediately in case of exception to let the caller handle it.
+ return v8::Handle<v8::Value>();
return script->Run();
}
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes