[tor-commits] [goptlib/master] Move SocksListener.Version.

dcf at torproject.org dcf at torproject.org
Mon Dec 9 02:49:51 UTC 2013


commit e0af87951d81eb67f706f104cb3a2b2af99a881c
Author: David Fifield <david at bamsoftware.com>
Date:   Sun Dec 8 11:04:48 2013 -0800

    Move SocksListener.Version.
---
 socks.go |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/socks.go b/socks.go
index d33afce..500a1fa 100644
--- a/socks.go
+++ b/socks.go
@@ -100,11 +100,6 @@ func (ln *SocksListener) Accept() (net.Conn, error) {
 	return ln.AcceptSocks()
 }
 
-// Returns "socks4", suitable to be included in a call to pt.Cmethod.
-func (ln *SocksListener) Version() string {
-	return "socks4"
-}
-
 // Call Accept on the wrapped net.Listener, do SOCKS negotiation, and return a
 // SocksConn. After accepting, you must call either conn.Grant or conn.Reject
 // (presumably after trying to connect to conn.Req.Target).
@@ -123,6 +118,11 @@ func (ln *SocksListener) AcceptSocks() (*SocksConn, error) {
 	return conn, nil
 }
 
+// Returns "socks4", suitable to be included in a call to pt.Cmethod.
+func (ln *SocksListener) Version() string {
+	return "socks4"
+}
+
 // Read a SOCKS4a connect request. Returns a SocksRequest.
 func readSocks4aConnect(s io.Reader) (req SocksRequest, err error) {
 	r := bufio.NewReader(s)





More information about the tor-commits mailing list