修改日志写入文件内

This commit is contained in:
bjdgyc
2021-02-22 14:35:29 +08:00
parent 665732fc03
commit 0baab68bb2
20 changed files with 166 additions and 70 deletions

View File

@@ -3,7 +3,6 @@ package sessdata
import (
"crypto/md5"
"fmt"
"log"
"math/rand"
"net"
"strconv"
@@ -191,7 +190,7 @@ func (s *Session) NewConn() *ConnSession {
func (cs *ConnSession) Close() {
cs.closeOnce.Do(func() {
log.Println("closeOnce:", cs.IpAddr)
base.Info("closeOnce:", cs.IpAddr)
cs.Sess.mux.Lock()
defer cs.Sess.mux.Unlock()