1
This commit is contained in:
@@ -59,13 +59,13 @@ func (t *TcpClient) handleConn(c net.Conn) {
|
||||
if strings.Contains(string(buffer[0:n]), "print_no") { // 清理缓存
|
||||
globals.SugarLogger.Debugf("=========buffer %s", string(buffer[0:n]))
|
||||
param := struct {
|
||||
PrintNo string `json:"print_no"`
|
||||
PrintNo json.Number `json:"print_no"`
|
||||
}{}
|
||||
if err := json.Unmarshal(buffer[0:n], ¶m); err != nil {
|
||||
c.Write([]byte(err.Error()))
|
||||
return
|
||||
}
|
||||
t.buildMsgMap(param.PrintNo)
|
||||
t.buildMsgMap(param.PrintNo.String())
|
||||
c.Write([]byte("ok"))
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user