mirror of
https://github.com/ton-blockchain/ton
synced 2025-03-09 15:40:10 +00:00
updated block header
1. Updated block header, proofs now contain more data Notice, that old proofs may become invalid in the future 2. Fixed message routing 3. Fixed block creator id in block header 4. Support for full proofs in tonlib 5. Support for partial state download 6. Some other bugfixes
This commit is contained in:
parent
bce33f588a
commit
13140ddf29
73 changed files with 2084 additions and 304 deletions
|
@ -218,12 +218,19 @@ bool CheckProof::init_parse(bool is_aux) {
|
|||
if (is_key_block_ && !shard.is_masterchain()) {
|
||||
return fatal_error("a non-masterchain block cannot be a key block");
|
||||
}
|
||||
block::gen::BlockExtra::Record extra;
|
||||
if (!is_aux) {
|
||||
/* FIXME: temp (uncommend later)
|
||||
if (!tlb::unpack_cell(std::move(blk.extra), extra)) {
|
||||
return fatal_error("cannot unpack extra header of block "s + blk_id.to_str());
|
||||
}
|
||||
*/
|
||||
}
|
||||
if (is_key_block_ && !is_aux) {
|
||||
// visit validator-set related fields in key blocks
|
||||
block::gen::BlockExtra::Record extra;
|
||||
block::gen::McBlockExtra::Record mc_extra;
|
||||
if (!(tlb::unpack_cell(std::move(blk.extra), extra) && tlb::unpack_cell(extra.custom->prefetch_ref(), mc_extra) &&
|
||||
mc_extra.key_block && mc_extra.config.not_null())) {
|
||||
if (!(tlb::unpack_cell(extra.custom->prefetch_ref(), mc_extra) && mc_extra.key_block &&
|
||||
mc_extra.config.not_null())) {
|
||||
return fatal_error("cannot unpack extra header of key masterchain block "s + blk_id.to_str());
|
||||
}
|
||||
auto cfg = block::Config::unpack_config(std::move(mc_extra.config));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue