This commit is contained in:
suyl
2021-07-22 10:52:35 +08:00
parent df4b2ad904
commit c7bc1abe3c

View File

@@ -374,8 +374,7 @@ func HandleTcpMessages() {
dao.UpdateEntity(db, printMsg, "Status") dao.UpdateEntity(db, printMsg, "Status")
flag: flag:
for { for {
select { obj, _ := <-printMsgChan
case obj, _ := <-printMsgChan:
if _, ok := obj.(*model.PrintMsg); ok { if _, ok := obj.(*model.PrintMsg); ok {
continue continue
} else { } else {
@@ -388,7 +387,6 @@ func HandleTcpMessages() {
} }
} }
} }
}
func doPrint2(printMsgChan chan interface{}) (err error) { func doPrint2(printMsgChan chan interface{}) (err error) {
var ( var (