Fix some errors if the config is unparseable. It should log an exception and carry on with defaults.
This commit is contained in:
parent
a776afe1bf
commit
76f3b26aa3
1 changed files with 10 additions and 0 deletions
|
@ -577,10 +577,20 @@ public class ForgeChunkManager
|
|||
chunkConstraints.put(mod, modCPT.getInt(25));
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
FMLLog.log(Level.SEVERE, e, "A critical error occured reading the forgeChunkLoading.cfg file, defaults will be used");
|
||||
}
|
||||
finally
|
||||
{
|
||||
config.save();
|
||||
if (dormantChunkCache == null)
|
||||
{
|
||||
dormantChunkCache = CacheBuilder.newBuilder().maximumSize(0).build();
|
||||
FMLLog.info("Configured a dormant chunk cache size of 0");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue