check nil pointer of tracerConfig

pull/4174/head
peekpi 3 years ago committed by Leo Chen
parent b161a39f59
commit 9f6c94e93e
  1. 2
      hmy/tracer.go

@ -418,7 +418,7 @@ func (hmy *Harmony) TraceBlock(ctx context.Context, block *types.Block, config *
default:
}
if *config.Tracer == "ParityBlockTracer" {
if config != nil && config.Tracer != nil && *config.Tracer == "ParityBlockTracer" {
return hmy.traceBlockNoThread(ctx, block, config)
}
// Create the parent state database

Loading…
Cancel
Save