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

Unified Diff: Source/WebCore/inspector/InspectorStyleSheet.cpp

Issue 11348012: Merge 132462 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1271/
Patch Set: Created 8 years, 2 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/inspector/InspectorStyleSheet.cpp
===================================================================
--- Source/WebCore/inspector/InspectorStyleSheet.cpp (revision 132834)
+++ Source/WebCore/inspector/InspectorStyleSheet.cpp (working copy)
@@ -844,16 +844,18 @@
return false;
}
- styleSheet->deleteRule(id.ordinal(), ec);
- if (ec)
- return false;
-
RefPtr<CSSRuleSourceData> sourceData = ruleSourceDataFor(rule->style());
if (!sourceData) {
ec = NOT_FOUND_ERR;
return false;
}
+ styleSheet->deleteRule(id.ordinal(), ec);
+ // |rule| MAY NOT be addressed after this line!
+
+ if (ec)
+ return false;
+
String sheetText = m_parsedStyleSheet->text();
sheetText.remove(sourceData->ruleHeaderRange.start, sourceData->ruleBodyRange.end - sourceData->ruleHeaderRange.start + 1);
m_parsedStyleSheet->setText(sheetText);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698