Bug 803688 - Re-land backed out part of bug 803688 now that we have bug 805207 fixed.
authorJustin Lebar <justin.lebar@gmail.com>
Wed, 31 Oct 2012 13:30:35 -0400
changeset 111955 74e7f7678c882f47ccd3ef5957cc84913b2e891a
parent 111954 303e6cbbb932ff42dc35041cf70a33468e76073b
child 111956 05f887e6dd933ffd5ad69aa27130ca1e437f154a
push idunknown
push userunknown
push dateunknown
bugs803688, 805207
milestone19.0a1
Bug 803688 - Re-land backed out part of bug 803688 now that we have bug 805207 fixed. This changeset reverts the partial-backout cset 5c82f5a5e90d, taking us back to the state we were in at bug 803688's initial landing, rev 592c3465a742.
mfbt/LinkedList.h
--- a/mfbt/LinkedList.h
+++ b/mfbt/LinkedList.h
@@ -249,16 +249,20 @@ template<typename T>
 class LinkedList
 {
   private:
     LinkedListElement<T> sentinel;
 
   public:
     LinkedList() : sentinel(LinkedListElement<T>::NODE_KIND_SENTINEL) { }
 
+    ~LinkedList() {
+      MOZ_ASSERT(isEmpty());
+    }
+
     /*
      * Add elem to the front of the list.
      */
     void insertFront(T* elem) {
       /* Bypass setNext()'s this->isInList() assertion. */
       sentinel.setNextUnsafe(elem);
     }