Browse Source

Updated close connection to no resp

Toby Chui 1 month ago
parent
commit
f1e13f5d3a
1 changed files with 2 additions and 2 deletions
  1. 2 2
      mod/dynamicproxy/Server.go

+ 2 - 2
mod/dynamicproxy/Server.go

@@ -215,12 +215,12 @@ func (h *ProxyHandler) handleRootRouting(w http.ResponseWriter, r *http.Request)
 		h.Parent.logRequest(r, false, 444, "root-no_resp", domainOnly)
 		hijacker, ok := w.(http.Hijacker)
 		if !ok {
-			h.serve404PageWithTemplate(w, r)
+			w.WriteHeader(http.StatusNoContent)
 			return
 		}
 		conn, _, err := hijacker.Hijack()
 		if err != nil {
-			h.serve404PageWithTemplate(w, r)
+			w.WriteHeader(http.StatusNoContent)
 			return
 		}
 		conn.Close()