This commit is contained in:
crusader 2017-11-29 20:13:37 +09:00
parent 1d6e7bc5b3
commit 57a60490c6

View File

@ -202,21 +202,21 @@ func (s *fasthttpWebSocket) ID() string {
// return s.sc, nil // return s.sc, nil
// } // }
// func (s *fasthttpWebSocket) NextWriter(messageType int) (io.WriteCloser, error) { func (s *fasthttpWebSocket) NextWriter(messageType int) (io.WriteCloser, error) {
// if 0 < s.sh.GetWriteTimeout() { if 0 < s.sh.GetWriteTimeout() {
// s.SetWriteDeadline(time.Now().Add(s.sh.GetWriteTimeout() * time.Second)) s.SetWriteDeadline(time.Now().Add(s.sh.GetWriteTimeout() * time.Second))
// } }
// return s.Conn.NextWriter(messageType) return s.Conn.NextWriter(messageType)
// } }
// func (s *fasthttpWebSocket) WriteMessage(messageType int, data []byte) error { func (s *fasthttpWebSocket) WriteMessage(messageType int, data []byte) error {
// if 0 < s.sh.GetWriteTimeout() { if 0 < s.sh.GetWriteTimeout() {
// s.SetWriteDeadline(time.Now().Add(s.sh.GetWriteTimeout() * time.Second)) s.SetWriteDeadline(time.Now().Add(s.sh.GetWriteTimeout() * time.Second))
// } }
// return s.Conn.WriteMessage(messageType, data) return s.Conn.WriteMessage(messageType, data)
// } }
func (s *fasthttpWebSocket) Close() error { func (s *fasthttpWebSocket) Close() error {
err := s.Conn.Close() err := s.Conn.Close()