From 3d7a6632240a450e4e68f0b86224c576e09936d7 Mon Sep 17 00:00:00 2001 From: Arthur Fabre Date: Fri, 28 Aug 2026 10:35:25 +0200 Subject: [PATCH] Remove leftover fmt.Errorf() after merging shift width check I merged two PRs successively, and broke builds: - eaafb3a1 "Reject cBPF shifts > 31" added a new errors.Errorf() call. - 71323da1 "Replace github.com/pkg/errors with stdlib" dropped the errors package. Change the added errors.Errorf() call over to fmt.Errorf() too. --- cbpfc.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cbpfc.go b/cbpfc.go index 5676aa3..243aad4 100644 --- a/cbpfc.go +++ b/cbpfc.go @@ -398,7 +398,7 @@ func validateInstructions(insns []bpf.Instruction) error { switch i.Op { case bpf.ALUOpShiftLeft, bpf.ALUOpShiftRight: if i.Val >= 32 { - return errors.Errorf("instruction %d shifts by %d, must be less than 32: %v", pc, i.Val, insn) + return fmt.Errorf("instruction %d shifts by %d, must be less than 32: %v", pc, i.Val, insn) } } }