mirror of
https://github.com/bluenviron/mediamtx.git
synced 2025-12-20 02:00:05 -08:00
Some checks failed
code_lint / go (push) Has been cancelled
code_lint / go_mod (push) Has been cancelled
code_lint / docs (push) Has been cancelled
code_lint / api_docs (push) Has been cancelled
code_test / test_64 (push) Has been cancelled
code_test / test_32 (push) Has been cancelled
code_test / test_e2e (push) Has been cancelled
this prevents zombie connections from piling up.
15 lines
261 B
Go
15 lines
261 B
Go
package httpp
|
|
|
|
import (
|
|
"net/http"
|
|
)
|
|
|
|
// set the Server header.
|
|
type handlerServerHeader struct {
|
|
h http.Handler
|
|
}
|
|
|
|
func (h *handlerServerHeader) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
|
w.Header().Set("Server", "mediamtx")
|
|
h.h.ServeHTTP(w, r)
|
|
}
|