handle a weird double start issue

This commit is contained in:
James Seibel
2026-04-21 21:25:44 -05:00
parent 945a2c0c5a
commit 3553ff8e60
@@ -80,9 +80,20 @@ public class DependencySetup
SingletonInjector.INSTANCE.bind(IConfigGui.class, ClassicConfigGUI.CONFIG_CORE_INTERFACE);
}
private static boolean renderingApiBindingsSet = false;
/** will be called from a DH thread, not the render thread */
public static void setRenderingApiBindings()
public synchronized static void setRenderingApiBindings()
{
// shouldn't happen, but there was a single report that this method was triggered twice
if (renderingApiBindingsSet)
{
LOGGER.warn("Rendering bindings already set, skipping. How did this happen?");
return;
}
renderingApiBindingsSet = true;
EDhApiRenderApi renderingApiEnum = Config.Client.Advanced.Graphics.Experimental.renderingApi.get();
if (renderingApiEnum == EDhApiRenderApi.AUTO)
{