[Bitcoin-development] Bug with handing of OP_RETURN?

Jeff Garzik jgarzik at bitpay.com
Sun May 4 13:25:35 UTC 2014


On Sat, May 3, 2014 at 3:15 PM, Mark Friedenbach <mark at monetize.io> wrote:
> Is it more complex? The current implementation using template matching
> seems more complex than `if script.vch[0] == OP_RETURN &&
> script.vch.size() < 42`

Not much more complex.

The template matches a two-chunk script with OP_RETURN + one pushdata
(or just OP_RETURN with no push).  The pushdata is further limited to
MAX_OP_RETURN_RELAY bytes.

-- 
Jeff Garzik
Bitcoin core developer and open source evangelist
BitPay, Inc.      https://bitpay.com/




More information about the bitcoin-dev mailing list