Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(265)

Unified Diff: Source/WebCore/dom/StyledElement.cpp

Issue 10824091: Merge 123377 - Crash when setting empty class name on a new element (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1180/
Patch Set: Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/svg/custom/empty-className-baseVal-crash-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/dom/StyledElement.cpp
===================================================================
--- Source/WebCore/dom/StyledElement.cpp (revision 124075)
+++ Source/WebCore/dom/StyledElement.cpp (working copy)
@@ -172,7 +172,7 @@
ensureAttributeData()->setClass(newClassString, shouldFoldCase);
if (DOMTokenList* classList = optionalClassList())
static_cast<ClassList*>(classList)->reset(newClassString);
- } else
+ } else if (attributeData())
attributeData()->clearClass();
setNeedsStyleRecalc();
}
« no previous file with comments | « LayoutTests/svg/custom/empty-className-baseVal-crash-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698