x/net: possible DEREF_AFTER_NULL error in http2/server.go #68679
Labels
WaitingForInfo
Issue is not actionable because of missing required information, which needs to be provided.
Milestone
Go version
go version go1.22.1 linux/amd64
Output of
go env
in your module/workspace:What did you do?
Hello! I have run SAST tool (https://svace.pages.ispras.ru/svace-website/en/) against x/net package codebase and found one minor null dereferce error (https://cwe.mitre.org/data/definitions/476.html).
Description: After having been compared to a nil value at server.go:2557, pointer 'b.conn' is passed as implicit 'this' parameter in call to function 'http2.serverConn.noteBodyReadFromHandler' at server.go:2560, where it is dereferenced at server.go:2434.
What did you see happen?
https://github.com/golang/net/blob/master/http2/server.go#L2560
What did you expect to see?
Possible version of fixed code:
The text was updated successfully, but these errors were encountered: