Stay

Words
19
Reading
1 min
Listen
Play
8y

sipa@sipa commented on this pull request.

In src/script/standard.cpp:

  •    // Sender provides N pubkeys, receivers provides M signatures
    
  •    mTemplates.insert(std::make_pair(TX_MULTISIG, CScript() << OP_SMALLINTEGER OP_PUBKEYS << OP_SMALLINTEGER OP_CHECKMULTISIG));
    

+static bool MatchMultisig(const CScript& script, unsigned int& required, std::vector& pubkeys)
+{

  • opcodetype opcode;
  • valtype data;
  • CScript::const_iterator it = script.begin();
  • if (script.size() 1 || script.back() != OP_CHECKMULTISIG) return false;
  • if (!script.GetOp(it, opcode, data) || (opcode != OP_0 && (opcode OP_1 || opcode OP_16))) return false;
  • required = CScript::DecodeOP_N(opcode);
  • while (script.GetOp(it, opcode, data) && CPubKey::ValidSize(data)) {
    Indeed (that's also what the old code does).

—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.

Stay | Ecency