Bug 1271460, don't leak editor created element objects, r=ehsan a=abillings
authorOlli Pettay <Olli.Pettay@helsinki.fi>
Fri, 13 May 2016 20:10:22 +0300
changeset 332889 5d6b894490f27d7e8ee098fd8279f2954e89a712
parent 332888 39d73775d903e37dfcd2f779e136033807789dc3
child 332890 54854c4cb6fbc60ba81f3dff7b455868c0f90cb4
push id6048
push userkmoir@mozilla.com
push dateMon, 06 Jun 2016 19:02:08 +0000
treeherdermozilla-beta@46d72a56c57d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersehsan, abillings
bugs1271460
milestone48.0a2
Bug 1271460, don't leak editor created element objects, r=ehsan a=abillings
editor/libeditor/nsHTMLInlineTableEditor.cpp
--- a/editor/libeditor/nsHTMLInlineTableEditor.cpp
+++ b/editor/libeditor/nsHTMLInlineTableEditor.cpp
@@ -104,17 +104,16 @@ nsHTMLEditor::HideInlineTableEditingUI()
   // get the presshell's document observer interface.
   nsCOMPtr<nsIPresShell> ps = GetPresShell();
   // We allow the pres shell to be null; when it is, we presume there
   // are no document observers to notify, but we still want to
   // UnbindFromTree.
 
   // get the root content node.
   nsCOMPtr<nsIContent> bodyContent = GetRoot();
-  NS_ENSURE_TRUE(bodyContent, NS_ERROR_FAILURE);
 
   DeleteRefToAnonymousNode(mAddColumnBeforeButton, bodyContent, ps);
   mAddColumnBeforeButton = nullptr;
   DeleteRefToAnonymousNode(mRemoveColumnButton, bodyContent, ps);
   mRemoveColumnButton = nullptr;
   DeleteRefToAnonymousNode(mAddColumnAfterButton, bodyContent, ps);
   mAddColumnAfterButton = nullptr;
   DeleteRefToAnonymousNode(mAddRowBeforeButton, bodyContent, ps);