Fix golangci-lint v2 compliance, make all passes clean
- Fix 314 errcheck violations (blank identifier for unrecoverable errors) - Fix errorlint violation (errors.Is for io.EOF) - Remove unused serveL7Route test helper - Simplify Duration.Seconds() selectors in tests - Remove unnecessary fmt.Sprintf in test - Migrate exclusion rules from issues.exclusions to linters.exclusions (v2 schema) - Add gosec test exclusions (G115, G304, G402, G705) - Disable fieldalignment govet analyzer (optimization, not correctness) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -50,8 +50,8 @@ const (
|
||||
// It reads only the exact bytes of the PROXY header, leaving the connection
|
||||
// positioned at the first byte after the header (e.g., TLS ClientHello).
|
||||
func Parse(conn net.Conn, deadline time.Time) (Header, error) {
|
||||
conn.SetReadDeadline(deadline)
|
||||
defer conn.SetReadDeadline(time.Time{})
|
||||
_ = conn.SetReadDeadline(deadline)
|
||||
defer func() { _ = conn.SetReadDeadline(time.Time{}) }()
|
||||
|
||||
// Read the first byte to determine version.
|
||||
var first [1]byte
|
||||
|
||||
Reference in New Issue
Block a user