From a149de332c455c90a675526251e1ae4c967d38ce Mon Sep 17 00:00:00 2001 From: liuxiaolong <liuxiaolong@aiotlink.com> Date: 星期五, 08 一月 2021 16:13:59 +0800 Subject: [PATCH] add log --- sbusClient.go | 1 - chanmanageApi.go | 3 +++ 2 files changed, 3 insertions(+), 1 deletions(-) diff --git a/chanmanageApi.go b/chanmanageApi.go index 3acd5f9..6281c7e 100644 --- a/chanmanageApi.go +++ b/chanmanageApi.go @@ -72,15 +72,18 @@ var res Result if err = json.Unmarshal(body, &res); err != nil { + logPrint("unmarshal to Result err:", err) return false, config } b, err := json.Marshal(res.Data) if err !=nil { + logPrint("marshal res.Data err:", err) return false,config } else { err = json.Unmarshal(b, &config) if err !=nil { + logPrint("unmarshal config err:", err) return false,config } else { return true,config diff --git a/sbusClient.go b/sbusClient.go index 679b6fc..9deb67c 100644 --- a/sbusClient.go +++ b/sbusClient.go @@ -164,7 +164,6 @@ if n := s.SendandrecvTimeout(nodes, data, &ret, 5000);n == 0 { //n==0琛ㄧず娌℃湁璇锋眰鎴愬姛 return nil, fmt.Errorf("doReq s.SendandrecvTimeout result n:%d", n) } else { - logPrint("doReq SendandrecvTimeout n:", n) if len(ret) > 0 { var retMsg MsgInfo err = json.Unmarshal(ret[0].Data, &retMsg) -- Gitblit v1.8.0