[FIX] NPE in ClientLauncherEntryPoint

This commit is contained in:
Gravita 2021-06-09 10:01:07 +07:00
parent 8ad6f7ccbe
commit 32a4729970
2 changed files with 10 additions and 10 deletions

View file

@ -40,15 +40,15 @@ public class MySQLCoreProvider extends AuthCoreProvider implements AuthSupportHa
public String tableHWID = "hwids";
public String tableHWIDLog = "hwidLog";
private String sqlFindHardwareByPublicKey;
private String sqlFindHardwareByData;
private String sqlFindHardwareById;
private String sqlCreateHardware;
private String sqlCreateHWIDLog;
private String sqlUpdateHardwarePublicKey;
private String sqlUpdateHardwareBanned;
private String sqlUpdateUsers;
private String sqlUsersByHwidId;
private transient String sqlFindHardwareByPublicKey;
private transient String sqlFindHardwareByData;
private transient String sqlFindHardwareById;
private transient String sqlCreateHardware;
private transient String sqlCreateHWIDLog;
private transient String sqlUpdateHardwarePublicKey;
private transient String sqlUpdateHardwareBanned;
private transient String sqlUpdateUsers;
private transient String sqlUsersByHwidId;
public PasswordVerifier passwordVerifier;
public double criticalCompareLevel = 1.0;

View file

@ -101,7 +101,6 @@ public static void main(String[] args) throws Throwable {
LogHelper.info("Using Sessions");
Request.setSession(params.session);
}
Request.service.registerEventHandler(new BasicLauncherEventHandler());
checkJVMBitsAndVersion(params.profile.getMinJavaVersion(), params.profile.getRecommendJavaVersion(), params.profile.getMaxJavaVersion(), params.profile.isWarnMissJavaVersion());
LauncherEngine.modulesManager.invokeEvent(new ClientProcessInitPhase(engine, params));
@ -121,6 +120,7 @@ public static void main(String[] args) throws Throwable {
boolean digest = !profile.isUpdateFastCheck();
LogHelper.debug("Restore sessions");
Request.restore();
Request.service.registerEventHandler(new BasicLauncherEventHandler());
Request.service.reconnectCallback = () ->
{
LogHelper.debug("WebSocket connect closed. Try reconnect");