1
This commit is contained in:
@@ -83,27 +83,12 @@ func handleConn(c net.Conn) error {
|
||||
for ip, pn := range PrintAddrAndIp.PrintObject {
|
||||
if ip == printRemoteAddr {
|
||||
PrintAddrAndIp.DelPrintAddrAndIp(printRemoteAddr)
|
||||
} else if pn != "" {
|
||||
printStatusOff[pn] = 1
|
||||
}
|
||||
}
|
||||
|
||||
for pn, ip := range PrintIpAndAddr.PrintObject {
|
||||
if ip == printRemoteAddr {
|
||||
PrintIpAndAddr.DelPrintIpAndAddr(pn)
|
||||
PrintObject.DelPrintObj(printNo)
|
||||
} else if pn != "" {
|
||||
printStatusOff[pn] = 1
|
||||
}
|
||||
}
|
||||
|
||||
globals.SugarLogger.Debugf("----可能存活打印机打印机:%s", utils.Format4Output(printStatusOff, false))
|
||||
for pn, _ := range PrintObject.PrintObject {
|
||||
if printStatusOff[pn] != 1 {
|
||||
globals.SugarLogger.Debugf("----已经不存在但是未删除打印机:%s", pn)
|
||||
PrintObject.DelPrintObj(pn)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user