[#node-BlockManager-WriteBlockUndo]
= xref:node.adoc[node]::xref:node/BlockManager.adoc[BlockManager]::WriteBlockUndo
:relfileprefix: ../../
:mrdocs:

Write a block&apos;s undo data to disk and record it in the block index&period;

== Synopsis

Declared in `&lt;node&sol;blockstorage&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
&lsqb;&lsqb;requires&lowbar;capability(0x7f95130c9428), requires&lowbar;capability(0x7f950163c718), requires&lowbar;capability(0x7f95241d9708), requires&lowbar;capability(0x7f951f330a08), requires&lowbar;capability(0x7f950b9c29c8), requires&lowbar;capability(0x7f95175c5118)&rsqb;&rsqb;
bool
WriteBlockUndo(
    xref:CBlockUndo.adoc[CBlockUndo] const& blockundo,
    xref:BlockValidationState.adoc[BlockValidationState]& state,
    xref:CBlockIndex.adoc[CBlockIndex]& block);
----

== Return Value

True on success, false if writing failed&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *blockundo*
| The undo data to store&period;
| *state*
| Validation state updated on failure&period;
| *block*
| The block index entry the undo data belongs to&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
