mirror of
https://gitee.com/san-bing/JChargePointProtocol
synced 2026-05-04 01:49:58 +08:00
连接创建后不发报文,ctx可能为空
This commit is contained in:
@@ -85,8 +85,10 @@ public class TcpSession extends ProtocolSession {
|
||||
public void close(SessionCloseReason reason) {
|
||||
super.close(reason);
|
||||
|
||||
ctx.flush();
|
||||
ctx.close();
|
||||
if (ctx != null) {
|
||||
ctx.flush();
|
||||
ctx.close();
|
||||
}
|
||||
}
|
||||
|
||||
public void writeAndFlush(ByteBuf byteBuf) {
|
||||
|
||||
Reference in New Issue
Block a user