diff --git a/pkg/utils/xml.go b/pkg/utils/xml.go index 664012a..411b82e 100644 --- a/pkg/utils/xml.go +++ b/pkg/utils/xml.go @@ -55,7 +55,7 @@ func XMLMarshal(obj interface{}, charset string) ([]byte, error) { } writer := transform.NewWriter(xmlBytes, t) - writer.Write([]byte(xmlStr)) + _, _ = writer.Write([]byte(xmlStr)) _ = writer.Close() } }() diff --git a/test/client_test.go b/test/client_test.go index b552e71..34b5e80 100644 --- a/test/client_test.go +++ b/test/client_test.go @@ -18,7 +18,8 @@ func TestClient(t *testing.T) { ctx, cancel := context.WithTimeout(context.Background(), 3*time.Second) ua, _ := sipgo.NewUA( - sipgo.WithUserAgentHostname("44050100002000000002@10.10.10.20:5099")) + sipgo.WithUserAgent("44050100002000000002"), + sipgo.WithUserAgentHostname("10.10.10.20:5099")) srv, _ := sipgo.NewServer(ua) // Creating server handle