Bug 530090 - Memory leaks in jArray in HTML5 parser. r=hsivonen.

This commit is contained in:
Zbyszek Skowron
2009-12-21 13:38:58 +02:00
parent c77a0ce277
commit 4b8110d400

View File

@@ -65,7 +65,7 @@ jArray<T,L>::jArray(T* const a, L const len)
template<class T, class L>
jArray<T,L>::jArray(L const len)
: arr(new T[len]), length(len)
: arr(len ? new T[len] : 0), length(len)
{
}