MCPcopy Create free account
hub / github.com/ElementsProject/elements / GetVirtualTransactionSize

Function GetVirtualTransactionSize

src/policy/policy.cpp:365–368  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

363}
364
365int64_t GetVirtualTransactionSize(int64_t nWeight, int64_t nSigOpCost, unsigned int bytes_per_sigop)
366{
367 return (std::max(nWeight, nSigOpCost * bytes_per_sigop) + WITNESS_SCALE_FACTOR - 1) / WITNESS_SCALE_FACTOR;
368}
369
370int64_t GetVirtualTransactionSize(const CTransaction& tx, int64_t nSigOpCost, unsigned int bytes_per_sigop)
371{

Callers 1

Calls 1

GetTransactionWeightFunction · 0.85

Tested by

no test coverage detected