Skip to content
Permalink
Browse files
We no longer need to be able to define log file wrappers.
  • Loading branch information
ahf committed Dec 22, 2018
1 parent 7d56ec4 commit 2d4cadf91f7da4fb43d8c1e85bb3c851fb660b0c
Showing with 0 additions and 13 deletions.
  1. +0 −13 pt.go
13 pt.go
@@ -171,19 +171,6 @@ func (w syncWriter) Write(p []byte) (n int, err error) {
// Writer to which pluggable transports negotiation messages are written. It
// defaults to a Writer that writes to os.Stdout and calls Sync after each
// write.
//
// You may, for example, log pluggable transports messages by defining a Writer
// that logs what is written to it:
// type logWriteWrapper struct {
// io.Writer
// }
//
// func (w logWriteWrapper) Write(p []byte) (int, error) {
// log.Print(string(p))
// return w.Writer.Write(p)
// }
// and then redefining Stdout:
// pt.Stdout = logWriteWrapper{pt.Stdout}
var Stdout io.Writer = syncWriter{os.Stdout}

// Represents an error that can happen during negotiation, for example

0 comments on commit 2d4cadf

Please sign in to comment.