| 237 | } |
| 238 | |
| 239 | bool CScript::IsPushOnly(const_iterator pc) const |
| 240 | { |
| 241 | while (pc < end()) |
| 242 | { |
| 243 | opcodetype opcode; |
| 244 | if (!GetOp(pc, opcode)) |
| 245 | return false; |
| 246 | // Note that IsPushOnly() *does* consider OP_RESERVED to be a |
| 247 | // push-type opcode, however execution of OP_RESERVED fails, so |
| 248 | // it's not relevant to P2SH/BIP62 as the scriptSig would fail prior to |
| 249 | // the P2SH special validation code being executed. |
| 250 | if (opcode > OP_16) |
| 251 | return false; |
| 252 | } |
| 253 | return true; |
| 254 | } |
| 255 | |
| 256 | bool CScript::IsPushOnly() const |
| 257 | { |
no outgoing calls