Skip to content

Commit

Permalink
perfschema: Do not ignore error when initialization.
Browse files Browse the repository at this point in the history
* perfschema: Do not ignore error when initialization.
  • Loading branch information
ngaut committed Apr 7, 2016
1 parent 204ed54 commit cfc2698
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion perfschema/perfschema.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
package perfschema

import (
"github.com/ngaut/log"
"github.com/pingcap/tidb/kv"
"github.com/pingcap/tidb/model"
"github.com/pingcap/tidb/table"
Expand Down Expand Up @@ -69,7 +70,10 @@ func NewPerfHandle(store kv.Storage) PerfSchema {
schema := PerfHandle.(*perfSchema)
schema.store = store
schema.historyHandles = make([]int64, 0, stmtsHistoryElemMax)
_ = schema.initialize()
err := schema.initialize()
if err != nil {
log.Fatal(err)
}
registerStatements()
return PerfHandle
}
Expand Down

0 comments on commit cfc2698

Please sign in to comment.