From 2350199b7cfa1a9d4173ab3f9750ee297a04c5f0 Mon Sep 17 00:00:00 2001 From: crusader Date: Thu, 22 Mar 2018 23:09:11 +0900 Subject: [PATCH] ing --- client/socket.go | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/client/socket.go b/client/socket.go index c896f32..9324c66 100644 --- a/client/socket.go +++ b/client/socket.go @@ -77,6 +77,19 @@ func (s *netSocket) Context() SocketContext { return s.ctx } +func (s *netSocket) Read(b []byte) (n int, err error) { + n, err = s.Conn.Read(b) + + logging.Logger().Debugf("Client Socket: read message[%s]", string(b)) + + return +} + +func (s *netSocket) Write(b []byte) (n int, err error) { + logging.Logger().Debugf("Client Socket: write message[%s]", string(b)) + return s.Conn.Write(b) +} + func (s *netSocket) Close() error { err := s.Conn.Close() s.sh.OnDisconnect(s)