diff --git a/http.go b/http.go index 8aed753..f54b2de 100644 --- a/http.go +++ b/http.go @@ -162,7 +162,7 @@ func (h *httpHandler) handleRequest(conn net.Conn, req *http.Request) { // probing resistance is enabled if ss := strings.SplitN(h.options.ProbeResist, ":", 2); len(ss) == 2 { switch ss[0] { - case "error": + case "code": resp.StatusCode, _ = strconv.Atoi(ss[1]) case "web": url := ss[1] diff --git a/http2.go b/http2.go index 8d82896..cdd7109 100644 --- a/http2.go +++ b/http2.go @@ -327,7 +327,7 @@ func (h *http2Handler) roundTrip(w http.ResponseWriter, r *http.Request) { // probing resistance is enabled if ss := strings.SplitN(h.options.ProbeResist, ":", 2); len(ss) == 2 { switch ss[0] { - case "error": + case "code": resp.StatusCode, _ = strconv.Atoi(ss[1]) case "web": url := ss[1]