gcs: check to see if sigScript exists before adding it

This commit is contained in:
Olaoluwa Osuntokun 2017-04-27 20:37:21 -07:00
parent 0830c7046f
commit c01c00e8b4

View file

@ -328,7 +328,9 @@ func BuildExtFilter(block *wire.MsgBlock) (*gcs.Filter, error) {
// Skip the inputs for the coinbase transaction // Skip the inputs for the coinbase transaction
if i != 0 { if i != 0 {
for _, txIn := range tx.TxIn { for _, txIn := range tx.TxIn {
b.AddScript(txIn.SignatureScript) if txIn.SignatureScript != nil {
b.AddScript(txIn.SignatureScript)
}
} }
} }
} }