mirror of
https://github.com/aler9/rtsp-simple-server
synced 2025-10-11 18:40:38 +08:00
hls: add Server header
This commit is contained in:
@@ -329,10 +329,10 @@ func (a *api) mwLog(ctx *gin.Context) {
|
||||
blw := &logWriter{ResponseWriter: ctx.Writer}
|
||||
ctx.Writer = blw
|
||||
|
||||
ctx.Next()
|
||||
|
||||
ctx.Writer.Header().Set("Server", "rtsp-simple-server")
|
||||
|
||||
ctx.Next()
|
||||
|
||||
var buf bytes.Buffer
|
||||
fmt.Fprintf(&buf, "%s %d %s\n", ctx.Request.Proto, ctx.Writer.Status(), http.StatusText(ctx.Writer.Status()))
|
||||
ctx.Writer.Header().Write(&buf)
|
||||
|
Reference in New Issue
Block a user