dgryski.semgrep-go.writestring.use-fprintf-not-write-fsprint
dgryski
Author
unknown
Download Count*
License
use fmt.Fprintf($W, $...VALS) instead of fmt.Sprintf and []byte conversion
Run Locally
Run in CI
Defintion
rules:
- id: use-fprintf-not-write-fsprint
patterns:
- pattern: $W.Write([]byte(fmt.Sprintf($...VALS)))
message: use fmt.Fprintf($W, $...VALS) instead of fmt.Sprintf and []byte conversion
languages:
- go
severity: ERROR
metadata:
license: MIT
Short Link: https://sg.run/0BKr