1
0
Эх сурвалжийг харах

set splice-timeout to 24 hours

patterniha 5 сар өмнө
parent
commit
b668333546
1 өөрчлөгдсөн 3 нэмэгдсэн , 3 устгасан
  1. 3 3
      proxy/proxy.go

+ 3 - 3
proxy/proxy.go

@@ -595,10 +595,10 @@ func CopyRawConnIfExist(ctx context.Context, readerConn net.Conn, writerConn net
 			errors.LogInfo(ctx, "CopyRawConn splice")
 			statWriter, _ := writer.(*dispatcher.SizeStatWriter)
 			//runtime.Gosched() // necessary
-			time.Sleep(time.Millisecond)    // without this, there will be a rare ssl error for freedom splice
-			timer.SetTimeoutIfNotOverridden(8 * time.Hour) // prevent leak, just in case
+			time.Sleep(time.Millisecond)                    // without this, there will be a rare ssl error for freedom splice
+			timer.SetTimeoutIfNotOverridden(24 * time.Hour) // prevent leak, just in case
 			if inTimer != nil {
-				inTimer.SetTimeoutIfNotOverridden(8 * time.Hour)
+				inTimer.SetTimeoutIfNotOverridden(24 * time.Hour)
 			}
 			w, err := tc.ReadFrom(readerConn)
 			if readCounter != nil {