Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error: http: request method or response status code does not allow body #71

Open
AnnatarHe opened this issue Nov 25, 2024 · 0 comments
Open

Comments

@AnnatarHe
Copy link

Hi gin team.

I think I found an issue with the timeout handler.
If a response has a 204 No Content status code, the handler will panic.

The reason is that when the handler finishes, it tries to write the response without checking the response code. See

if _, err := tw.ResponseWriter.Write(buffer.Bytes()); err != nil {
.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant