get_ops_in_block does not take the maximum value of block_num when include_reversible it's enabled
Sending the maximum 32-bit number to the block_num
parameter in combination with the enabled option include_reversible
throw:
"Assert Exception:*blockRangeBegin < *blockRangeEnd: Wrong block range",
It's because here:
uint32_t rangeBegin = blockNum; // 4294967295
uint32_t rangeEnd = blockNum + 1; // 0
is no check before blockNum
incrementation and it overflows.
Request which triggers execption:
{
"jsonrpc": "2.0",
"method": "account_history_api.get_ops_in_block",
"params": {
"block_num": 4294967295,
"only_virtual": true,
"include_reversible": true
},
"id": 1
}
Edited by Piotr Batko