Title: [231294] trunk/Source/WebCore
Revision
231294
Author
[email protected]
Date
2018-05-02 20:40:29 -0700 (Wed, 02 May 2018)

Log Message

Remove superfluous check for a null attribute value check in Element::removeAttributeInternal
https://bugs.webkit.org/show_bug.cgi?id=185227

Reviewed by Chris Dumez.

Removed the check. The attribute value string can never be null.

* dom/Element.cpp:
(WebCore::Element::removeAttributeInternal):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (231293 => 231294)


--- trunk/Source/WebCore/ChangeLog	2018-05-03 03:19:33 UTC (rev 231293)
+++ trunk/Source/WebCore/ChangeLog	2018-05-03 03:40:29 UTC (rev 231294)
@@ -1,3 +1,15 @@
+2018-05-02  Ryosuke Niwa  <[email protected]>
+
+        Remove superfluous check for a null attribute value check in Element::removeAttributeInternal
+        https://bugs.webkit.org/show_bug.cgi?id=185227
+
+        Reviewed by Chris Dumez.
+
+        Removed the check. The attribute value string can never be null.
+
+        * dom/Element.cpp:
+        (WebCore::Element::removeAttributeInternal):
+
 2018-05-02  Zalan Bujtas  <[email protected]>
 
         [LFC] Implement LayoutContext::createDisplayBox

Modified: trunk/Source/WebCore/dom/Element.cpp (231293 => 231294)


--- trunk/Source/WebCore/dom/Element.cpp	2018-05-03 03:19:33 UTC (rev 231293)
+++ trunk/Source/WebCore/dom/Element.cpp	2018-05-03 03:40:29 UTC (rev 231294)
@@ -2363,9 +2363,8 @@
         return;
     }
 
-    if (!valueBeingRemoved.isNull())
-        willModifyAttribute(name, valueBeingRemoved, nullAtom());
-
+    ASSERT(!valueBeingRemoved.isNull());
+    willModifyAttribute(name, valueBeingRemoved, nullAtom());
     {
         Style::AttributeChangeInvalidation styleInvalidation(*this, name, valueBeingRemoved, nullAtom());
         elementData.removeAttribute(index);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to