Bug 805287 - Block scripts in PrepareEditorEvent::Run; r=ehsan a=lsblakk
authorAryeh Gregor <ayg@aryeh.name>
Sun, 04 Nov 2012 14:27:49 +0200
changeset 117338 895e866ddec3eea1220c0bd58b55e784a89a2b5a
parent 117337 6735d6d137510961339a65b0a477dac0da7885b0
child 117339 8914200121e93849f54ed81e5d85cc302f437b28
push id239
push userakeybl@mozilla.com
push dateThu, 03 Jan 2013 21:54:43 +0000
treeherdermozilla-release@3a7b66445659 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersehsan, lsblakk
bugs805287
milestone18.0a2
Bug 805287 - Block scripts in PrepareEditorEvent::Run; r=ehsan a=lsblakk
content/html/content/src/nsTextEditorState.cpp
--- a/content/html/content/src/nsTextEditorState.cpp
+++ b/content/html/content/src/nsTextEditorState.cpp
@@ -1021,16 +1021,18 @@ public:
     NS_ENSURE_TRUE(mState, NS_ERROR_NULL_POINTER);
 
     // Transfer the saved value to the editor if we have one
     const nsAString *value = nullptr;
     if (!mCurrentValue.IsEmpty()) {
       value = &mCurrentValue;
     }
 
+    nsAutoScriptBlocker scriptBlocker;
+
     mState->PrepareEditor(value);
 
     mState->mValueTransferInProgress = false;
 
     return NS_OK;
   }
 
 private: