mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-20 04:09:51 +00:00
Handle logging during shutdown better on the server, by not
closing the logfile before the server itself has shutdown. Signed-off-by: cpw <[email protected]>
This commit is contained in:
3 files changed
+14
-4
No files matched your search
@@ -86,6 +86,8 @@ public class ClientModLoader
|
||||
|
||||
public static void begin(final Minecraft minecraft, final ResourcePackList<ClientResourcePackInfo> defaultResourcePacks, final IReloadableResourceManager mcResourceManager, DownloadingPackFinder metadataSerializer)
|
||||
{
|
||||
// force log4j to shutdown logging in a shutdown hook. This is because we disable default shutdown hook so the server properly logs it's shutdown
|
||||
Runtime.getRuntime().addShutdownHook(new Thread(LogManager::shutdown));
|
||||
loading = true;
|
||||
ClientModLoader.mc = minecraft;
|
||||
SidedProvider.setClient(()->minecraft);
|
||||
|
||||
Reference in new issue
Block a user