From feaf6b4a8c4a77b173e8df95854db7adfb6bd457 Mon Sep 17 00:00:00 2001 From: Andy Clement Date: Wed, 29 May 2013 07:59:47 -0700 Subject: [PATCH] Fixes #8: ensure array is always large enough --- .../src/main/java/org/springsource/loaded/NameRegistry.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/org.springsource.loaded/src/main/java/org/springsource/loaded/NameRegistry.java b/org.springsource.loaded/src/main/java/org/springsource/loaded/NameRegistry.java index 749484d..4976634 100644 --- a/org.springsource.loaded/src/main/java/org/springsource/loaded/NameRegistry.java +++ b/org.springsource.loaded/src/main/java/org/springsource/loaded/NameRegistry.java @@ -80,7 +80,7 @@ public class NameRegistry { int id = getIdFor(slashedClassName); if (id == -1) { id = nextTypeId++; - if (id >= allocatedIds.length) { + if (nextTypeId >= allocatedIds.length) { size = size + 10; // need to make more room String[] newAllocatedIds = new String[size];