Add in env var to enable yamux debug logging
License: MIT Signed-off-by: Jeromy <jeromyj@gmail.com>
Jeromy committed
Feb 8, 2017 at 22:36 UTC
66e18261160f1363f097a42df1248f95a11b0443
1 file changed
+4
core/core.go
+4
@@ -234,6 +234,10 @@ func makeSmuxTransport(mplexExp bool) smux.Transport {
234
LogOutput: ioutil.Discard,
235
}
236
237
+ if os.Getenv("YAMUX_DEBUG") != "" {
238
+ ymxtpt.LogOutput = os.Stderr
239
+ }
240
+
241
mstpt.AddTransport("/yamux/1.0.0", ymxtpt)
242
243
mstpt.AddTransport("/spdy/3.1.0", spdy.Transport)