MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / IsToKeyID

Function IsToKeyID

src/compressor.cpp:20–29  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18 */
19
20static bool IsToKeyID(const CScript& script, CKeyID &hash)
21{
22 if (script.size() == 25 && script[0] == OP_DUP && script[1] == OP_HASH160
23 && script[2] == 20 && script[23] == OP_EQUALVERIFY
24 && script[24] == OP_CHECKSIG) {
25 memcpy(&hash, &script[3], 20);
26 return true;
27 }
28 return false;
29}
30
31static bool IsToScriptID(const CScript& script, CScriptID &hash)
32{

Callers 1

CompressScriptFunction · 0.85

Calls 2

memcpyFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected