Browse Source

Reset the head after clearing the linked list.
Credit to nchoiset for reporting this issue. Fix #2244.

Yao Wei Tjong 姚伟忠 8 years ago
parent
commit
bab0216bf1
1 changed files with 1 additions and 0 deletions
  1. 1 0
      Source/Urho3D/Container/LinkedList.h

+ 1 - 0
Source/Urho3D/Container/LinkedList.h

@@ -78,6 +78,7 @@ public:
             delete element;
             element = next;
         }
+        head_ = nullptr;
     }
 
     /// Insert an element at the beginning.