summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsnowleo <schneeleo@gmail.com>2011-07-18 22:39:01 +0200
committersnowleo <schneeleo@gmail.com>2011-07-18 22:39:01 +0200
commit7aea8a3fcee1bc72de87873a63a2b1c2bdbc96a8 (patch)
tree9f70589f4ba2f3043147251e4e8f6b9b7dae7277
parentd2bc7e01a251c21ff4b9de7193e8a6187d7ffd37 (diff)
downloadEssentials-7aea8a3fcee1bc72de87873a63a2b1c2bdbc96a8.tar
Essentials-7aea8a3fcee1bc72de87873a63a2b1c2bdbc96a8.tar.gz
Essentials-7aea8a3fcee1bc72de87873a63a2b1c2bdbc96a8.tar.lz
Essentials-7aea8a3fcee1bc72de87873a63a2b1c2bdbc96a8.tar.xz
Essentials-7aea8a3fcee1bc72de87873a63a2b1c2bdbc96a8.zip
NPE fix in InventoryWorkaround
-rw-r--r--Essentials/src/com/earth2me/essentials/InventoryWorkaround.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/Essentials/src/com/earth2me/essentials/InventoryWorkaround.java b/Essentials/src/com/earth2me/essentials/InventoryWorkaround.java
index e163cfb58..9aee4033c 100644
--- a/Essentials/src/com/earth2me/essentials/InventoryWorkaround.java
+++ b/Essentials/src/com/earth2me/essentials/InventoryWorkaround.java
@@ -103,6 +103,11 @@ public final class InventoryWorkaround
for (int i = 0; i < combined.length; i++)
{
final ItemStack item = combined[i];
+ if (item == null)
+ {
+ continue;
+ }
+
while (true)
{
// Do we already have a stack of it?