Also don't choke expanding a zero size array.

git-svn-id: https://samskivert.googlecode.com/svn/trunk@1544 6335cc39-0255-0410-8fd6-9bcaacd3b74c
This commit is contained in:
ray
2004-12-13 06:43:50 +00:00
parent 11c7589db5
commit ae896e9b5b
@@ -487,7 +487,7 @@ public class ListUtil
int size = list.length;
// expand size by powers of two until we're big enough
while (size <= index) {
size *= 2;
size = Math.max(size * 2, DEFAULT_LIST_SIZE);
}
// create a new list and copy the contents