فهرست منبع

Proactively clean up HTTP proxy resources

Rod Hynes 11 سال پیش
والد
کامیت
0f0fb84bf1
1فایلهای تغییر یافته به همراه1 افزوده شده و 0 حذف شده
  1. 1 0
      psiphon/httpProxy.go

+ 1 - 0
psiphon/httpProxy.go

@@ -70,6 +70,7 @@ func NewHttpProxy(listenPort int, tunnel *Tunnel, stoppedSignal chan struct{}) (
 func (proxy *HttpProxy) Close() {
 func (proxy *HttpProxy) Close() {
 	proxy.listener.Close()
 	proxy.listener.Close()
 	proxy.waitGroup.Wait()
 	proxy.waitGroup.Wait()
+	proxy.httpRelay.CloseIdleConnections()
 }
 }
 
 
 // ServeHTTP receives HTTP requests and proxies them. CONNECT requests
 // ServeHTTP receives HTTP requests and proxies them. CONNECT requests