aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Johnson <benbjohnson@yahoo.com>2016-09-06 14:09:29 -0600
committerGitHub <noreply@github.com>2016-09-06 14:09:29 -0600
commite72f08ddb5a52992c0a44c7dda9316c7333938b2 (patch)
tree34ab2ef37df52338b6fe9769e4e4647c6e2507bd
parentMerge pull request #578 from resin-os/align-fix (diff)
parenttask#560 print leaf k/v with right value (diff)
downloaddedo-e72f08ddb5a52992c0a44c7dda9316c7333938b2.tar.gz
dedo-e72f08ddb5a52992c0a44c7dda9316c7333938b2.tar.xz
Merge pull request #561 from zhujun2006/master
task#560 print leaf k/v with right value
-rw-r--r--cmd/bolt/main.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmd/bolt/main.go b/cmd/bolt/main.go
index a132ec0..29e393f 100644
--- a/cmd/bolt/main.go
+++ b/cmd/bolt/main.go
@@ -542,9 +542,9 @@ func (cmd *PageCommand) PrintLeaf(w io.Writer, buf []byte) error {
b := (*bucket)(unsafe.Pointer(&e.value()[0]))
v = fmt.Sprintf("<pgid=%d,seq=%d>", b.root, b.sequence)
} else if isPrintable(string(e.value())) {
- k = fmt.Sprintf("%q", string(e.value()))
+ v = fmt.Sprintf("%q", string(e.value()))
} else {
- k = fmt.Sprintf("%x", string(e.value()))
+ v = fmt.Sprintf("%x", string(e.value()))
}
fmt.Fprintf(w, "%s: %s\n", k, v)