mirror of
https://github.com/netbirdio/ice.git
synced 2026-05-22 17:10:58 -07:00
+1
-1
@@ -66,7 +66,7 @@ func NewCandidateRelay(config *CandidateRelayConfig) (*CandidateRelay, error) {
|
||||
func (c *CandidateRelay) close() error {
|
||||
err := c.candidateBase.close()
|
||||
if c.onClose != nil {
|
||||
c.onClose()
|
||||
err = c.onClose()
|
||||
c.onClose = nil
|
||||
}
|
||||
return err
|
||||
|
||||
@@ -21,8 +21,8 @@ type virtualNet struct {
|
||||
}
|
||||
|
||||
func (v *virtualNet) close() {
|
||||
v.server.Close() // nolint:errcheck
|
||||
v.wan.Stop()
|
||||
v.server.Close() // nolint:errcheck,gosec
|
||||
v.wan.Stop() // nolint:errcheck,gosec
|
||||
}
|
||||
|
||||
func buildVNet(natType *vnet.NATType) (*virtualNet, error) {
|
||||
@@ -250,10 +250,7 @@ func closePipe(t *testing.T, ca *Conn, cb *Conn) bool {
|
||||
return false
|
||||
}
|
||||
err = cb.Close()
|
||||
if !assert.NoError(t, err, "should succeed") {
|
||||
return false
|
||||
}
|
||||
return true
|
||||
return assert.NoError(t, err, "should succeed")
|
||||
}
|
||||
|
||||
func TestConnectivityVNet(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user