commit f66072fb1957499cb5f72b57813b279b3d1173cc Author: David Fifield david@bamsoftware.com Date: Fri Feb 1 01:59:35 2019 -0700
Don't set the helper proxy when not using the helper.
It causes an error when it uses something unsupported, like username:password.
This was a regression added in 3fe68658f433adb2b8bec215d4daf48e81003cf7. --- meek-client/meek-client.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/meek-client/meek-client.go b/meek-client/meek-client.go index dbe6e42..4838b68 100644 --- a/meek-client/meek-client.go +++ b/meek-client/meek-client.go @@ -439,10 +439,12 @@ func main() { } log.Printf("using proxy %s", options.ProxyURL.String()) httpRoundTripper.Proxy = http.ProxyURL(options.ProxyURL) - err = helperRoundTripper.SetProxy(options.ProxyURL) - if err != nil { - pt.ProxyError(err.Error()) - log.Fatal(fmt.Sprintf("proxy error: %s", err)) + if options.UseHelper { + err = helperRoundTripper.SetProxy(options.ProxyURL) + if err != nil { + pt.ProxyError(err.Error()) + log.Fatal(fmt.Sprintf("proxy error: %s", err)) + } } if ptInfo.ProxyURL != nil { pt.ProxyDone()
tor-commits@lists.torproject.org