summaryrefslogtreecommitdiff
path: root/pkg/binstruct/binint
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@lukeshu.com>2022-06-11 22:30:35 -0600
committerLuke Shumaker <lukeshu@lukeshu.com>2022-06-11 22:38:48 -0600
commit6fc5d416a289235dd4bb56d29fb96c5a003ea89f (patch)
treee35bb16c46c2ad8d8563b42e12a1e95cbd936dc7 /pkg/binstruct/binint
parentf1a212cddb8dc051c510327c365da42e30b23ab9 (diff)
use %v when possible
Exceptions are - the occasional %x when the type is a basic int - %w - %q - %T - whenever print_tree.go needs to be dumb for compatibility with C
Diffstat (limited to 'pkg/binstruct/binint')
-rw-r--r--pkg/binstruct/binint/builtins.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/binstruct/binint/builtins.go b/pkg/binstruct/binint/builtins.go
index 9af3c35..04fc477 100644
--- a/pkg/binstruct/binint/builtins.go
+++ b/pkg/binstruct/binint/builtins.go
@@ -7,7 +7,7 @@ import (
func needNBytes(t interface{}, dat []byte, n int) error {
if len(dat) < n {
- return fmt.Errorf("%T.UnmarshalBinary: need at least %d bytes, only have %d", t, n, len(dat))
+ return fmt.Errorf("%T.UnmarshalBinary: need at least %v bytes, only have %v", t, n, len(dat))
}
return nil
}