From b5a7d52f21448d4307f37eee0801f4e71aba46b8 Mon Sep 17 00:00:00 2001 From: Dave Collins Date: Fri, 16 Jan 2015 10:11:35 -0600 Subject: [PATCH] Add comments to Tor discovery errors. --- discovery.go | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/discovery.go b/discovery.go index c46138a5..672556ae 100644 --- a/discovery.go +++ b/discovery.go @@ -23,8 +23,16 @@ const ( ) var ( + // ErrTorInvalidAddressResponse indicates an invalid address was + // returned by the Tor DNS resolver. ErrTorInvalidAddressResponse = errors.New("invalid address response") - ErrTorInvalidProxyResponse = errors.New("invalid proxy response") + + // ErrTorInvalidProxyResponse indicates the Tor proxy returned a + // response in an unexpected format. + ErrTorInvalidProxyResponse = errors.New("invalid proxy response") + + // ErrTorUnrecognizedAuthMethod indicates the authentication method + // provided is not recognized. ErrTorUnrecognizedAuthMethod = errors.New("invalid proxy authentication method") torStatusErrors = map[byte]error{