p455w0rd's Library

p455w0rd's Library

52M Downloads

Server crash on world loadup when removing endergetic from my pack

MasterBuilder747 opened this issue ยท 2 comments

commented

I decided that an incomplete in dev end expansion mod would be unnecessary for my pack, but all of a sudden when loading a new world your mod (of all the ones in my pack, according to vanillafix) crashes my game :(

Using mod version 2.1.44
Endergetic: 0.0.1
CF page (they use the CF issue tracker): here
crash here

commented

Same issue. ConcurrentModificationException specifically when loading the world. Singleplayer. Doesn't always happen, ofcourse.

Stacktrace:

java.util.ConcurrentModificationException
    at java.util.ArrayList$Itr.checkForComodification(Unknown Source)
    at java.util.ArrayList$Itr.next(Unknown Source)
    at p455w0rdslib.handlers.ProcessHandlerClient.onClientTick(ProcessHandlerClient.java:40)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_1246_ProcessHandlerClient_onClientTick_ClientTickEvent.invoke(.dynamic)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90)
    at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:182)
    at net.minecraftforge.fml.common.FMLCommonHandler.onPreClientTick(FMLCommonHandler.java:344)
    at net.minecraft.client.Minecraft.runTick(Minecraft.java:1708)
    at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1098)
    at net.minecraft.client.Minecraft.run(Minecraft.java:3942)
    at net.minecraft.client.main.Main.main(SourceFile:123)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
    at net.minecraft.launchwrapper.Launch.main(Launch.java:28)

Checking the source, it seems an IProcess (probably from a different mod using this library) is removing itself while inside the iterator (when the updateProcess method is called on it). The best way to prevent this is probably to make a copy of the ArrayList before iterating it, so that even in that event it doesn't cause a ConcurrentModificationException.

commented

thx..this is really old code left over from 1.7.10 when it was in p455w0rdsThings..thanks for pointing it out :)