Minor fixes

This commit is contained in:
世界
2022-09-11 08:36:52 +08:00
parent ebf5cbf1b9
commit 7e09beb0c3
3 changed files with 11 additions and 7 deletions

View File

@@ -60,7 +60,11 @@ func (s *ShadowTLS) DialContext(ctx context.Context, network string, destination
if err != nil {
return nil, err
}
return tls.ClientHandshake(ctx, conn, s.tlsConfig)
_, err = tls.ClientHandshake(ctx, conn, s.tlsConfig)
if err != nil {
return nil, err
}
return conn, nil
}
func (s *ShadowTLS) ListenPacket(ctx context.Context, destination M.Socksaddr) (net.PacketConn, error) {