1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-12-30 05:56:54 -05:00

switch to bytes.Equal

This commit is contained in:
Darien Raymond 2018-11-16 17:00:16 +01:00
parent 1089a887e0
commit 248099eca5
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169

View File

@ -3,10 +3,9 @@
package tls
import (
"bytes"
"crypto/x509"
"sync"
"v2ray.com/core/common/compare"
)
type certPoolCache struct {
@ -18,7 +17,7 @@ type certPoolCache struct {
func (c *certPoolCache) hasCert(cert []byte) bool {
for _, xCert := range c.extraCerts {
if compare.BytesEqual(xCert, cert) {
if bytes.Equal(xCert, cert) {
return true
}
}