Cause found
This commit is contained in:
parent
415b09b03f
commit
18ab3e8014
|
@ -5,6 +5,7 @@
|
|||
package net.md_5.bungee.netty;
|
||||
|
||||
import io.netty.channel.Channel;
|
||||
import io.netty.channel.ChannelFuture;
|
||||
import io.netty.channel.ChannelHandlerContext;
|
||||
|
||||
public class ChannelWrapper {
|
||||
|
@ -15,10 +16,15 @@ public class ChannelWrapper {
|
|||
this.ch = ctx.channel();
|
||||
}
|
||||
|
||||
public synchronized void write(final Object packet) { // This is a problem, the packets ARE being sent but arent coming to client
|
||||
public synchronized void write(final Object packet) { // This is a problem, the packets ARE being sent but they are null
|
||||
if (!this.closed) {
|
||||
System.out.println("[ChannelWrapper] - trying to send packet");
|
||||
this.ch.write(packet);
|
||||
StackTraceElement[] stackTrace = Thread.currentThread().getStackTrace();
|
||||
StackTraceElement element = stackTrace[2];
|
||||
System.out.println("null packets coming from: " + element.getClassName()); // UserConnection
|
||||
ChannelFuture cf = this.ch.write(packet);
|
||||
if (!cf.isSuccess()) {
|
||||
System.out.println("Couldnt send packet: " + cf.cause());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue