storage/raft: Fix panic when no Join TLS info is being used (#10801)
This commit is contained in:
parent
672101ddb9
commit
64c4850b45
|
@ -230,7 +230,9 @@ func parseTLSInfo(leaderInfo *LeaderJoinInfo) (*tls.Config, error) {
|
|||
return nil, err
|
||||
}
|
||||
}
|
||||
tlsConfig.ServerName = leaderInfo.LeaderTLSServerName
|
||||
if tlsConfig != nil {
|
||||
tlsConfig.ServerName = leaderInfo.LeaderTLSServerName
|
||||
}
|
||||
|
||||
return tlsConfig, nil
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue