fmt.Print 제거

main
jjLee 2 years ago
parent 271798ddda
commit d28a621f14

@ -27,7 +27,7 @@ func NewSIPSignal(sipType string, sessionId int, id string, toid string, ra icsn
l := icslog.GetIcsLog() l := icslog.GetIcsLog()
if strings.ToUpper(sipType) == "REGI" { if strings.ToUpper(sipType) == "REGI" {
fmt.Println("#### Received REGI ") // fmt.Println("#### Received REGI ")
p := simproc.NewSIPProc(buf[:rlen]) p := simproc.NewSIPProc(buf[:rlen])
from := p.SIPHeader.From from := p.SIPHeader.From
id = strings.Split(strings.Split(from, "@")[0], ":")[1] id = strings.Split(strings.Split(from, "@")[0], ":")[1]
@ -110,7 +110,7 @@ func NewReadSIP(sessionId int, callid string, ip string, rTPTxPort int, ra icsne
localSIPUDP.Close() localSIPUDP.Close()
return nil, 0, siperr return nil, 0, siperr
} else { } else {
fmt.Printf("####### Receved SIP Packet > \r\n%s \r\n", buf[:rlen]) // fmt.Printf("####### Receved SIP Packet > \r\n%s \r\n", buf[:rlen])
l.Printf(icslog.LOG_LEVEL_INFO, sessionId, "Recved SIP Packet [%s:%d]->[%s:%d]>\n%s\n===================", l.Printf(icslog.LOG_LEVEL_INFO, sessionId, "Recved SIP Packet [%s:%d]->[%s:%d]>\n%s\n===================",
remAddr.IP.String(), remAddr.Port, rsaddr.IPv4String, rsaddr.Port, buf[:rlen]) remAddr.IP.String(), remAddr.Port, rsaddr.IPv4String, rsaddr.Port, buf[:rlen])
} }
@ -120,7 +120,7 @@ func NewReadSIP(sessionId int, callid string, ip string, rTPTxPort int, ra icsne
func WriteSIP(sipType string, sessionId int, ra icsnet.IcsNetAddr, callid string, ip string, rTPTxPort int, laddr *icsnet.IcsNetAddr, rsaddr *icsnet.IcsNetAddr, lsaddr *icsnet.IcsNetAddr, sendMsg string, localSIPUDP *icsnet.IcsUDPNet) *icserror.IcsError { func WriteSIP(sipType string, sessionId int, ra icsnet.IcsNetAddr, callid string, ip string, rTPTxPort int, laddr *icsnet.IcsNetAddr, rsaddr *icsnet.IcsNetAddr, lsaddr *icsnet.IcsNetAddr, sendMsg string, localSIPUDP *icsnet.IcsUDPNet) *icserror.IcsError {
l := icslog.GetIcsLog() l := icslog.GetIcsLog()
l.Printf(icslog.LOG_LEVEL_INFO, sessionId, "Call ID [%s]", callid) l.Printf(icslog.LOG_LEVEL_INFO, sessionId, "Call ID [%s]", callid)
fmt.Println("send msg", sendMsg) // fmt.Println("send msg", sendMsg)
_, werr := localSIPUDP.Write([]byte(sendMsg)) _, werr := localSIPUDP.Write([]byte(sendMsg))
if werr != nil { if werr != nil {

Loading…
Cancel
Save