mirror of
https://github.com/PaperMC/Velocity.git
synced 2024-12-03 06:52:16 +08:00
Wrap plugin message copies in unreleasable copies.
Trying to track down a very weird issue that barely makes sense to me.
This commit is contained in:
parent
89e1a07448
commit
8a3b6403da
@ -146,7 +146,7 @@ public class BackendPlaySessionHandler implements MinecraftSessionHandler {
|
||||
.thenAcceptAsync(pme -> {
|
||||
if (pme.getResult().isAllowed() && !playerConnection.isClosed()) {
|
||||
PluginMessage copied = new PluginMessage(packet.getChannel(),
|
||||
Unpooled.wrappedBuffer(copy));
|
||||
Unpooled.unreleasableBuffer(Unpooled.wrappedBuffer(copy)));
|
||||
playerConnection.write(copied);
|
||||
}
|
||||
}, playerConnection.eventLoop())
|
||||
|
@ -230,7 +230,7 @@ public class ClientPlaySessionHandler implements MinecraftSessionHandler {
|
||||
server.getEventManager().fire(event).thenAcceptAsync(pme -> {
|
||||
if (pme.getResult().isAllowed()) {
|
||||
PluginMessage message = new PluginMessage(packet.getChannel(),
|
||||
Unpooled.wrappedBuffer(copy));
|
||||
Unpooled.unreleasableBuffer(Unpooled.wrappedBuffer(copy)));
|
||||
backendConn.write(message);
|
||||
}
|
||||
}, backendConn.eventLoop())
|
||||
|
Loading…
Reference in New Issue
Block a user