Fix the order of arguments of client copyLoop to match the call.

The call was
	copyLoop(socks, snowflake)
but the function signature was
	func copyLoop(WebRTC, SOCKS io.ReadWriter) {

The mistake was mostly harmless, because both arguments were treated the
same, except that error logs would have reported the wrong direction.
This commit is contained in:
David Fifield 2020-01-28 02:55:17 -07:00
parent db1ba4791b
commit bc5498cb4b

View file

@ -48,7 +48,7 @@ func Handler(socks SocksConnector, snowflakes SnowflakeCollector) error {
// Exchanges bytes between two ReadWriters.
// (In this case, between a SOCKS and WebRTC connection.)
func copyLoop(WebRTC, SOCKS io.ReadWriter) {
func copyLoop(SOCKS, WebRTC io.ReadWriter) {
var wg sync.WaitGroup
wg.Add(2)
go func() {