From 6be65856430ba11c2b64eda7dd3b9258e3770f9a Mon Sep 17 00:00:00 2001 From: "Johan T. Halseth" Date: Thu, 21 Oct 2021 22:54:48 +0200 Subject: [PATCH] kvdb/bolt_compact: filter out non-ASCII from bucket name before printing Printing the raw bucket name lead to weird characters and even sounds being printed. --- kvdb/bolt_compact.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kvdb/bolt_compact.go b/kvdb/bolt_compact.go index e46c55f94..72d470f9b 100644 --- a/kvdb/bolt_compact.go +++ b/kvdb/bolt_compact.go @@ -220,7 +220,8 @@ func (cmd *compacter) walk(db *bbolt.DB, walkFn walkFunc) error { return tx.ForEach(func(name []byte, b *bbolt.Bucket) error { // This will log the top level buckets only to give the // user some sense of progress. - log.Debugf("Compacting top level bucket %s", name) + log.Debugf("Compacting top level bucket '%s'", + LoggableKeyName(name)) return cmd.walkBucket( b, nil, name, nil, b.Sequence(), walkFn,