Skip to content

crypto/tls: Replace errors.New() with error exported variables #9116

Description

@gopherbot

by edrocksit:

crypto/tls makes heavy use of errors.New() instead of exported error variables. This
requires anyone checking for specific errors to have to do a basic string compare which
is error prone if the error strings crypto/tls uses ever change.

What does 'go version' print?
go1.3.3 windows/amd64

What steps reproduce the problem?
Do something that makes crypto/tls return an error. In my case with the rest api I'm
using approximately 1 of every 30-50 requests returns "remote error: handshake
failure". The only way to test for this and retry is to do a basic string compare.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions