Skip to content
This repository has been archived by the owner on Dec 8, 2021. It is now read-only.

Commit

Permalink
restore: remove hack.String
Browse files Browse the repository at this point in the history
  • Loading branch information
lonng committed Dec 26, 2018
1 parent 2826e79 commit 531aa02
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lightning/restore/restore.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ import (
verify "github.com/pingcap/tidb-lightning/lightning/verification"
tidbcfg "github.com/pingcap/tidb/config"
"github.com/pingcap/tidb/meta/autoid"
"github.com/pingcap/tidb/util/hack"
"github.com/pingcap/tidb/util/kvencoder"
"github.com/pkg/errors"
)
Expand Down Expand Up @@ -1387,7 +1386,7 @@ func (cr *chunkRestore) restore(

// sql -> kv
start = time.Now()
kvs, _, err := kvEncoder.SQL2KV(hack.String(buffer.Bytes()))
kvs, _, err := kvEncoder.SQL2KV(buffer.String())
encodeDur := time.Since(start)
encodeTotalDur += encodeDur
metric.BlockEncodeSecondsHistogram.Observe(encodeDur.Seconds())
Expand Down

0 comments on commit 531aa02

Please sign in to comment.