Browse Source
Explicitly ensure length > 0 to sign vote extension
Signed-off-by: Thane Thomson <connect@thanethomson.com>
thane/7655-vote-extensions
Thane Thomson
3 years ago
No known key found for this signature in database
GPG Key ID: 19811391D676EE45
1 changed files with
1 additions and
1 deletions
-
types/priv_validator.go
|
|
@ -95,7 +95,7 @@ func (pv MockPV) SignVote(ctx context.Context, chainID string, vote *tmproto.Vot |
|
|
|
return err |
|
|
|
} |
|
|
|
vote.Signature = sig |
|
|
|
if vote.Extension != nil { |
|
|
|
if len(vote.Extension) > 0 { |
|
|
|
vote.ExtensionSignature, err = pv.PrivKey.Sign(vote.Extension) |
|
|
|
if err != nil { |
|
|
|
return err |
|
|
|