CommandHelper

CommandHelper

46.5k Downloads

Uncaught byte array IndexOutOfBoundsException

LadyCailin opened this issue ยท 1 comments

commented

CMDHELPER-2620 - Reported by opoq on 2013-04-07 01:36:09 UTC

Where '/run $ = eval($)':

18:31:31 [INFO] CH: Running original command on player opoq ----> /run @a = string_get_bytes('test') for(@i = 0, @i < 4, @i++) {msg(ba_get_int(@a, @i))}
18:31:31 [INFO] An unexpected exception occured during the execution of a script.
18:31:31 [SEVERE] java.lang.IndexOutOfBoundsException
18:31:31 [SEVERE]       at java.nio.Buffer.checkIndex(Buffer.java:537)
18:31:31 [SEVERE]       at java.nio.HeapByteBuffer.getInt(HeapByteBuffer.java:359)
18:31:31 [SEVERE]       at com.laytonsmith.core.constructs.CByteArray.getInt(CByteArray.java:191)
18:31:31 [SEVERE]       at com.laytonsmith.core.functions.ByteArrays$ba_get_int.exec(ByteArrays.java:152)
18:31:31 [SEVERE]       at com.laytonsmith.core.Script.eval(Script.java:296)
18:31:31 [SEVERE]       at com.laytonsmith.core.Script.eval(Script.java:257)
18:31:31 [SEVERE]       at com.laytonsmith.core.functions.DataHandling$forelse.execs(DataHandling.java:452)
18:31:31 [SEVERE]       at com.laytonsmith.core.functions.DataHandling$_for.execs(DataHandling.java:305)
18:31:31 [SEVERE]       at com.laytonsmith.core.Script.eval(Script.java:248)
18:31:31 [SEVERE]       at com.laytonsmith.core.Script.eval(Script.java:257)
18:31:31 [SEVERE]       at com.laytonsmith.core.Script.seval(Script.java:192)
18:31:31 [SEVERE]       at com.laytonsmith.core.functions.Meta$eval.execs(Meta.java:352)
18:31:31 [SEVERE]       at com.laytonsmith.core.Script.eval(Script.java:248)
18:31:31 [SEVERE]       at com.laytonsmith.core.MethodScriptCompiler.execute(MethodScriptCompiler.java:1489)
18:31:31 [SEVERE]       at com.laytonsmith.core.MethodScriptCompiler.execute(MethodScriptCompiler.java:1454)
18:31:31 [SEVERE]       at com.laytonsmith.core.Script.run(Script.java:146)
18:31:31 [SEVERE]       at com.laytonsmith.core.AliasCore.alias(AliasCore.java:137)
18:31:31 [SEVERE]       at com.laytonsmith.commandhelper.CommandHelperListener.runAlias(CommandHelperListener.java:87)
18:31:31 [SEVERE]       at com.laytonsmith.commandhelper.CommandHelperListener.onPlayerCommandPreprocess(CommandHelperListener.java:132)
18:31:31 [SEVERE]       at sun.reflect.GeneratedMethodAccessor138.invoke(Unknown Source)
18:31:31 [SEVERE]       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
18:31:31 [SEVERE]       at java.lang.reflect.Method.invoke(Method.java:616)
18:31:31 [SEVERE]       at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:425)
18:31:31 [SEVERE]       at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62)
18:31:31 [SEVERE]       at org.bukkit.plugin.TimedRegisteredListener.callEvent(TimedRegisteredListener.java:26)
18:31:31 [SEVERE]       at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:479)
18:31:31 [SEVERE]       at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:464)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.PlayerConnection.handleCommand(PlayerConnection.java:971)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.PlayerConnection.chat(PlayerConnection.java:896)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.PlayerConnection.a(PlayerConnection.java:840)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.Packet3Chat.handle(Packet3Chat.java:44)
18:31:31 [SEVERE]       at org.spigotmc.netty.NettyNetworkManager.b(NettyNetworkManager.java:174)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.PlayerConnection.d(PlayerConnection.java:113)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.ServerConnection.b(SourceFile:35)
18:31:31 [SEVERE]       at org.spigotmc.netty.NettyServerConnection.b(NettyServerConnection.java:66)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.MinecraftServer.r(MinecraftServer.java:582)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.DedicatedServer.r(DedicatedServer.java:229)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.MinecraftServer.q(MinecraftServer.java:471)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.MinecraftServer.run(MinecraftServer.java:403)
18:31:31 [SEVERE]       at net.minecraft.server.v1_5_R2.ThreadServerApplication.run(SourceFile:573)
commented

Comment by LadyCailin on 2013-06-25 17:01:08 UTC

Fixed in next build.