close server down link

pull/432/head
Darien Raymond 2017-04-04 11:20:07 +02:00
parent 619c7b9e39
commit 7195c17af6
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169
1 changed files with 2 additions and 2 deletions

View File

@ -321,11 +321,11 @@ func (w *ServerWorker) remove(id uint16) {
func handle(ctx context.Context, s *session, output buf.Writer) {
writer := NewResponseWriter(s.id, output)
defer writer.Close()
if err := buf.PipeUntilEOF(signal.BackgroundTimer(), s.input, writer); err != nil {
log.Info("Proxyman|Mux|ServerWorker: Session ", s.id, " ends: ", err)
}
writer.Close()
s.closeDownlink()
}
func (w *ServerWorker) run(ctx context.Context) {