diff --git a/editor/libeditor/html/nsHTMLEditRules.cpp b/editor/libeditor/html/nsHTMLEditRules.cpp
index 0613c81f860..7e639e64a0f 100644
--- a/editor/libeditor/html/nsHTMLEditRules.cpp
+++ b/editor/libeditor/html/nsHTMLEditRules.cpp
@@ -2403,6 +2403,8 @@ nsHTMLEditRules::WillMakeList(nsISelection *aSelection,
if (NS_FAILED(res)) return res;
if (IsInlineNode(curNode))
prevListItem = listItem;
+ else
+ prevListItem = nsnull;
}
}
else