Переглянути джерело

lib/relay: Prevent lock nil deref when creation dynamic client (#6175)

Simon Frei 6 роки тому
батько
коміт
de886b3f22
1 змінених файлів з 1 додано та 1 видалено
  1. 1 1
      lib/relay/client/dynamic.go

+ 1 - 1
lib/relay/client/dynamic.go

@@ -33,7 +33,7 @@ func newDynamicClient(uri *url.URL, certs []tls.Certificate, invitations chan pr
 		certs:    certs,
 		certs:    certs,
 		timeout:  timeout,
 		timeout:  timeout,
 	}
 	}
-	c.commonClient = newCommonClient(invitations, c.serve, c.String())
+	c.commonClient = newCommonClient(invitations, c.serve, fmt.Sprintf("dynamicClient@%p", c))
 	return c
 	return c
 }
 }