Title: [128607] trunk
- Revision
- 128607
- Author
- [email protected]
- Date
- 2012-09-14 07:01:17 -0700 (Fri, 14 Sep 2012)
Log Message
[EFL] Attempt to create a theme for 0 sized element leads to assertion hit
https://bugs.webkit.org/show_bug.cgi?id=96743
Patch by Mikhail Pozdnyakov <[email protected]> on 2012-09-14
Reviewed by Kenneth Rohde Christiansen.
Source/WebCore:
RenderThemeEfl was not supposed to be created for the elements with '0' size and had an assertion
on that causing crash in debug mode.
Test: fast/forms/range/slider-zero-size-crash.html
* platform/efl/RenderThemeEfl.cpp:
(WebCore::RenderThemeEfl::ThemePartCacheEntry::create):
LayoutTests:
RenderThemeEfl was not supposed to be created for the elements with '0' size and had an assertion
on that causing crash in debug mode.
* fast/forms/range/slider-zero-size-crash-expected.txt: Added.
* fast/forms/range/slider-zero-size-crash.html: Added.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (128606 => 128607)
--- trunk/LayoutTests/ChangeLog 2012-09-14 13:41:24 UTC (rev 128606)
+++ trunk/LayoutTests/ChangeLog 2012-09-14 14:01:17 UTC (rev 128607)
@@ -1,3 +1,16 @@
+2012-09-14 Mikhail Pozdnyakov <[email protected]>
+
+ [EFL] Attempt to create a theme for 0 sized element leads to assertion hit
+ https://bugs.webkit.org/show_bug.cgi?id=96743
+
+ Reviewed by Kenneth Rohde Christiansen.
+
+ RenderThemeEfl was not supposed to be created for the elements with '0' size and had an assertion
+ on that causing crash in debug mode.
+
+ * fast/forms/range/slider-zero-size-crash-expected.txt: Added.
+ * fast/forms/range/slider-zero-size-crash.html: Added.
+
2012-09-14 Sudarsana Nagineni <[email protected]>
[EFL] Gardening of failing tests
Added: trunk/LayoutTests/fast/forms/range/slider-zero-size-crash-expected.txt (0 => 128607)
--- trunk/LayoutTests/fast/forms/range/slider-zero-size-crash-expected.txt (rev 0)
+++ trunk/LayoutTests/fast/forms/range/slider-zero-size-crash-expected.txt 2012-09-14 14:01:17 UTC (rev 128607)
@@ -0,0 +1,2 @@
+
+This test passes if it does not crash.
Added: trunk/LayoutTests/fast/forms/range/slider-zero-size-crash.html (0 => 128607)
--- trunk/LayoutTests/fast/forms/range/slider-zero-size-crash.html (rev 0)
+++ trunk/LayoutTests/fast/forms/range/slider-zero-size-crash.html 2012-09-14 14:01:17 UTC (rev 128607)
@@ -0,0 +1,17 @@
+<!DOCTYPE html>
+<html>
+<head>
+<title>A slider with '0' size does not lead to a crash</title>
+<link rel="author" title="Mikhail Pozdnyakov" href="" />
+<script>
+ if (window.testRunner)
+ testRunner.dumpAsText();
+</script>
+</head>
+<input type="range" id="slider"/>
+<script>
+document.getElementById("slider").style.height="0px"
+document.getElementById("slider").style.width="0px";
+</script>
+<p>This test passes if it does not crash.</p>
+</html>
Modified: trunk/Source/WebCore/ChangeLog (128606 => 128607)
--- trunk/Source/WebCore/ChangeLog 2012-09-14 13:41:24 UTC (rev 128606)
+++ trunk/Source/WebCore/ChangeLog 2012-09-14 14:01:17 UTC (rev 128607)
@@ -1,3 +1,18 @@
+2012-09-14 Mikhail Pozdnyakov <[email protected]>
+
+ [EFL] Attempt to create a theme for 0 sized element leads to assertion hit
+ https://bugs.webkit.org/show_bug.cgi?id=96743
+
+ Reviewed by Kenneth Rohde Christiansen.
+
+ RenderThemeEfl was not supposed to be created for the elements with '0' size and had an assertion
+ on that causing crash in debug mode.
+
+ Test: fast/forms/range/slider-zero-size-crash.html
+
+ * platform/efl/RenderThemeEfl.cpp:
+ (WebCore::RenderThemeEfl::ThemePartCacheEntry::create):
+
2012-09-14 Andrey Kosyakov <[email protected]>
Web Inspector: reuse WebInspector.ProgressIndicator in Audits panel
Modified: trunk/Source/WebCore/platform/efl/RenderThemeEfl.cpp (128606 => 128607)
--- trunk/Source/WebCore/platform/efl/RenderThemeEfl.cpp 2012-09-14 13:41:24 UTC (rev 128606)
+++ trunk/Source/WebCore/platform/efl/RenderThemeEfl.cpp 2012-09-14 14:01:17 UTC (rev 128607)
@@ -196,9 +196,8 @@
RenderThemeEfl::ThemePartCacheEntry* RenderThemeEfl::ThemePartCacheEntry::create(const String& themePath, FormType type, const IntSize& size)
{
ASSERT(!themePath.isEmpty());
- ASSERT(!size.isEmpty());
- if (isFormElementTooLargeToDisplay(size)) {
+ if (isFormElementTooLargeToDisplay(size) || size.isEmpty()) {
EINA_LOG_ERR("Cannot render an element of size %dx%d.", size.width(), size.height());
return 0;
}
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes