Mirror von
https://github.com/PaperMC/Velocity.git
synchronisiert 2024-11-17 05:20:14 +01:00
Fix connection error spamming (#847)
* Fix "pointers" for players never being used lol * Added Platform Facet API to add Type pointers * Remove duplicate * Fix some connection things * Make checkstyle happy?
Dieser Commit ist enthalten in:
Ursprung
47cd9faf65
Commit
cae41c33a1
@ -706,6 +706,11 @@ public class ConnectedPlayer implements MinecraftConnectionAssociation, Player,
|
|||||||
switch (status.getStatus()) {
|
switch (status.getStatus()) {
|
||||||
// Impossible/nonsensical cases
|
// Impossible/nonsensical cases
|
||||||
case ALREADY_CONNECTED:
|
case ALREADY_CONNECTED:
|
||||||
|
logger.error("{}: already connected to {}",
|
||||||
|
this,
|
||||||
|
status.getAttemptedConnection().getServerInfo().getName()
|
||||||
|
);
|
||||||
|
break;
|
||||||
case CONNECTION_IN_PROGRESS:
|
case CONNECTION_IN_PROGRESS:
|
||||||
// Fatal case
|
// Fatal case
|
||||||
case CONNECTION_CANCELLED:
|
case CONNECTION_CANCELLED:
|
||||||
@ -1179,12 +1184,8 @@ public class ConnectedPlayer implements MinecraftConnectionAssociation, Player,
|
|||||||
if (status != null && !status.isSuccessful()) {
|
if (status != null && !status.isSuccessful()) {
|
||||||
if (!status.isSafe()) {
|
if (!status.isSafe()) {
|
||||||
handleConnectionException(status.getAttemptedConnection(), throwable, false);
|
handleConnectionException(status.getAttemptedConnection(), throwable, false);
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (throwable != null) {
|
|
||||||
logger.error("Exception during connect; status = {}", status, throwable);
|
|
||||||
}
|
|
||||||
}, connection.eventLoop())
|
}, connection.eventLoop())
|
||||||
.thenApply(x -> x);
|
.thenApply(x -> x);
|
||||||
}
|
}
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren