mirror of
https://github.com/aaru-dps/libaaruformat.git
synced 2025-12-16 19:24:40 +00:00
661 lines
156 KiB
HTML
661 lines
156 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||
<head>
|
||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||
<meta name="generator" content="Doxygen 1.14.0"/>
|
||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||
<title>libaaruformat: src/create.c Source File</title>
|
||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||
<script type="text/javascript" src="jquery.js"></script>
|
||
<script type="text/javascript" src="dynsections.js"></script>
|
||
<script type="text/javascript" src="clipboard.js"></script>
|
||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||
<script type="text/javascript" src="navtreedata.js"></script>
|
||
<script type="text/javascript" src="navtree.js"></script>
|
||
<script type="text/javascript" src="cookie.js"></script>
|
||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||
<script type="text/javascript" src="search/search.js"></script>
|
||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||
</head>
|
||
<body>
|
||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||
<div id="titlearea">
|
||
<table cellspacing="0" cellpadding="0">
|
||
<tbody>
|
||
<tr id="projectrow">
|
||
<td id="projectalign">
|
||
<div id="projectname">libaaruformat<span id="projectnumber"> 1.0</span>
|
||
</div>
|
||
<div id="projectbrief">Aaru Data Preservation Suite - Format Library</div>
|
||
</td>
|
||
</tr>
|
||
</tbody>
|
||
</table>
|
||
</div>
|
||
<!-- end header part -->
|
||
<!-- Generated by Doxygen 1.14.0 -->
|
||
<script type="text/javascript">
|
||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||
</script>
|
||
<script type="text/javascript">
|
||
$(function() { codefold.init(); });
|
||
</script>
|
||
<script type="text/javascript" src="menudata.js"></script>
|
||
<script type="text/javascript" src="menu.js"></script>
|
||
<script type="text/javascript">
|
||
$(function() {
|
||
initMenu('',true,false,'search.php','Search',true);
|
||
$(function() { init_search(); });
|
||
});
|
||
</script>
|
||
<div id="main-nav"></div>
|
||
</div><!-- top -->
|
||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||
<div id="nav-tree">
|
||
<div id="nav-tree-contents">
|
||
<div id="nav-sync" class="sync"></div>
|
||
</div>
|
||
</div>
|
||
<div id="splitbar" style="-moz-user-select:none;"
|
||
class="ui-resizable-handle">
|
||
</div>
|
||
</div>
|
||
<script type="text/javascript">
|
||
$(function(){initNavTree('create_8c_source.html','',''); });
|
||
</script>
|
||
<div id="container">
|
||
<div id="doc-content">
|
||
<!-- window showing the filter options -->
|
||
<div id="MSearchSelectWindow"
|
||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||
</div>
|
||
|
||
<!-- iframe showing the search results (closed by default) -->
|
||
<div id="MSearchResultsWindow">
|
||
<div id="MSearchResults">
|
||
<div class="SRPage">
|
||
<div id="SRIndex">
|
||
<div id="SRResults"></div>
|
||
<div class="SRStatus" id="Loading">Loading...</div>
|
||
<div class="SRStatus" id="Searching">Searching...</div>
|
||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="header">
|
||
<div class="headertitle"><div class="title">create.c</div></div>
|
||
</div><!--header-->
|
||
<div class="contents">
|
||
<a href="create_8c.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="comment">/*</span></div>
|
||
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="comment"> * This file is part of the Aaru Data Preservation Suite.</span></div>
|
||
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span><span class="comment"> * Copyright (c) 2019-2025 Natalia Portillo.</span></div>
|
||
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span><span class="comment"> *</span></div>
|
||
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span><span class="comment"> * This library is free software; you can redistribute it and/or modify</span></div>
|
||
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span><span class="comment"> * it under the terms of the GNU Lesser General Public License as</span></div>
|
||
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span><span class="comment"> * published by the Free Software Foundation; either version 2.1 of the</span></div>
|
||
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span><span class="comment"> * License, or (at your option) any later version.</span></div>
|
||
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span><span class="comment"> *</span></div>
|
||
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span><span class="comment"> * This library is distributed in the hope that it will be useful, but</span></div>
|
||
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span><span class="comment"> * WITHOUT ANY WARRANTY; without even the implied warranty of</span></div>
|
||
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span><span class="comment"> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU</span></div>
|
||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="comment"> * Lesser General Public License for more details.</span></div>
|
||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span><span class="comment"> *</span></div>
|
||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span><span class="comment"> * You should have received a copy of the GNU Lesser General Public</span></div>
|
||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span><span class="comment"> * License along with this library; if not, see <http://www.gnu.org/licenses/>.</span></div>
|
||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span><span class="comment"> */</span></div>
|
||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span><span class="preprocessor">#include <errno.h></span></div>
|
||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span><span class="preprocessor">#include <stdbool.h></span></div>
|
||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span><span class="preprocessor">#include <stdint.h></span></div>
|
||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span><span class="preprocessor">#include <stdio.h></span></div>
|
||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span><span class="preprocessor">#include <stdlib.h></span></div>
|
||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span><span class="preprocessor">#include <string.h></span></div>
|
||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> </div>
|
||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span><span class="preprocessor">#include "<a class="code" href="aaruformat_8h.html">aaruformat.h</a>"</span></div>
|
||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span><span class="preprocessor">#include "<a class="code" href="enums_8h.html">enums.h</a>"</span></div>
|
||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span><span class="preprocessor">#include "<a class="code" href="internal_8h.html">internal.h</a>"</span></div>
|
||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span><span class="preprocessor">#include "<a class="code" href="log_8h.html">log.h</a>"</span></div>
|
||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> </div>
|
||
<div class="foldopen" id="foldopen00030" data-start="{" data-end="}">
|
||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"><a class="line" href="create_8c.html#ae92275e097d4193d960bb97311b9cd78"> 30</a></span><span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code hl_function" href="create_8c.html#ae92275e097d4193d960bb97311b9cd78">cleanup_failed_create</a>(<a class="code hl_struct" href="structaaruformat__context.html">aaruformat_context</a> *ctx)</div>
|
||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span>{</div>
|
||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> <span class="keywordflow">if</span>(ctx == NULL) <span class="keywordflow">return</span>;</div>
|
||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> </div>
|
||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a18bee1dd72fd1ca4957ff6ddfebce343">sector_hash_map</a> != NULL)</div>
|
||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> {</div>
|
||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> <a class="code hl_function" href="hash__map_8h.html#ab885e8c5bedaf6f3cca1877e378fd04f">free_map</a>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a18bee1dd72fd1ca4957ff6ddfebce343">sector_hash_map</a>);</div>
|
||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a18bee1dd72fd1ca4957ff6ddfebce343">sector_hash_map</a> = NULL;</div>
|
||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> }</div>
|
||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> </div>
|
||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab97a719a5b4186695b67143db7376152">index_entries</a> != NULL)</div>
|
||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> {</div>
|
||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> utarray_free(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab97a719a5b4186695b67143db7376152">index_entries</a>);</div>
|
||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab97a719a5b4186695b67143db7376152">index_entries</a> = NULL;</div>
|
||
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> }</div>
|
||
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span> </div>
|
||
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3c7b902731274622296d04564b193b64">user_data_ddt2</a> != NULL)</div>
|
||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> {</div>
|
||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> free(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3c7b902731274622296d04564b193b64">user_data_ddt2</a>);</div>
|
||
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3c7b902731274622296d04564b193b64">user_data_ddt2</a> = NULL;</div>
|
||
<div class="line"><a id="l00050" name="l00050"></a><span class="lineno"> 50</span> }</div>
|
||
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno"> 51</span> </div>
|
||
<div class="line"><a id="l00052" name="l00052"></a><span class="lineno"> 52</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a729b87257c0b5d1e9abf1af133a4b0f3">spamsum_context</a> != NULL)</div>
|
||
<div class="line"><a id="l00053" name="l00053"></a><span class="lineno"> 53</span> {</div>
|
||
<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span> <a class="code hl_function" href="decls_8h.html#a6fe74704e44be7adfaa2ce676f3c3de4">aaruf_spamsum_free</a>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a729b87257c0b5d1e9abf1af133a4b0f3">spamsum_context</a>);</div>
|
||
<div class="line"><a id="l00055" name="l00055"></a><span class="lineno"> 55</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a729b87257c0b5d1e9abf1af133a4b0f3">spamsum_context</a> = NULL;</div>
|
||
<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"> 56</span> }</div>
|
||
<div class="line"><a id="l00057" name="l00057"></a><span class="lineno"> 57</span> </div>
|
||
<div class="line"><a id="l00058" name="l00058"></a><span class="lineno"> 58</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a8b89a7e0e6369dad38e23dabaf4b49a4">blake3_context</a> != NULL)</div>
|
||
<div class="line"><a id="l00059" name="l00059"></a><span class="lineno"> 59</span> {</div>
|
||
<div class="line"><a id="l00060" name="l00060"></a><span class="lineno"> 60</span> free(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a8b89a7e0e6369dad38e23dabaf4b49a4">blake3_context</a>);</div>
|
||
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"> 61</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a8b89a7e0e6369dad38e23dabaf4b49a4">blake3_context</a> = NULL;</div>
|
||
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span> }</div>
|
||
<div class="line"><a id="l00063" name="l00063"></a><span class="lineno"> 63</span> </div>
|
||
<div class="line"><a id="l00064" name="l00064"></a><span class="lineno"> 64</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a510b72290e2bd50e02ef8a2387aa829d">ecc_cd_context</a> != NULL)</div>
|
||
<div class="line"><a id="l00065" name="l00065"></a><span class="lineno"> 65</span> {</div>
|
||
<div class="line"><a id="l00066" name="l00066"></a><span class="lineno"> 66</span> free(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a510b72290e2bd50e02ef8a2387aa829d">ecc_cd_context</a>);</div>
|
||
<div class="line"><a id="l00067" name="l00067"></a><span class="lineno"> 67</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a510b72290e2bd50e02ef8a2387aa829d">ecc_cd_context</a> = NULL;</div>
|
||
<div class="line"><a id="l00068" name="l00068"></a><span class="lineno"> 68</span> }</div>
|
||
<div class="line"><a id="l00069" name="l00069"></a><span class="lineno"> 69</span> </div>
|
||
<div class="line"><a id="l00070" name="l00070"></a><span class="lineno"> 70</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ad3d5494e23b07418e9fbd22c3771e534">readableSectorTags</a> != NULL)</div>
|
||
<div class="line"><a id="l00071" name="l00071"></a><span class="lineno"> 71</span> {</div>
|
||
<div class="line"><a id="l00072" name="l00072"></a><span class="lineno"> 72</span> free(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ad3d5494e23b07418e9fbd22c3771e534">readableSectorTags</a>);</div>
|
||
<div class="line"><a id="l00073" name="l00073"></a><span class="lineno"> 73</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ad3d5494e23b07418e9fbd22c3771e534">readableSectorTags</a> = NULL;</div>
|
||
<div class="line"><a id="l00074" name="l00074"></a><span class="lineno"> 74</span> }</div>
|
||
<div class="line"><a id="l00075" name="l00075"></a><span class="lineno"> 75</span> </div>
|
||
<div class="line"><a id="l00076" name="l00076"></a><span class="lineno"> 76</span> <span class="comment">// ApplicationVersion and Version are fixed-size arrays, not pointers - no need to free</span></div>
|
||
<div class="line"><a id="l00077" name="l00077"></a><span class="lineno"> 77</span> </div>
|
||
<div class="line"><a id="l00078" name="l00078"></a><span class="lineno"> 78</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab516fae594bde4f76b75488d0a3ca3a8">imageStream</a> != NULL)</div>
|
||
<div class="line"><a id="l00079" name="l00079"></a><span class="lineno"> 79</span> {</div>
|
||
<div class="line"><a id="l00080" name="l00080"></a><span class="lineno"> 80</span> fclose(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab516fae594bde4f76b75488d0a3ca3a8">imageStream</a>);</div>
|
||
<div class="line"><a id="l00081" name="l00081"></a><span class="lineno"> 81</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab516fae594bde4f76b75488d0a3ca3a8">imageStream</a> = NULL;</div>
|
||
<div class="line"><a id="l00082" name="l00082"></a><span class="lineno"> 82</span> }</div>
|
||
<div class="line"><a id="l00083" name="l00083"></a><span class="lineno"> 83</span> </div>
|
||
<div class="line"><a id="l00084" name="l00084"></a><span class="lineno"> 84</span> free(ctx);</div>
|
||
<div class="line"><a id="l00085" name="l00085"></a><span class="lineno"> 85</span>}</div>
|
||
</div>
|
||
<div class="line"><a id="l00086" name="l00086"></a><span class="lineno"> 86</span></div>
|
||
<div class="foldopen" id="foldopen00279" data-start="{" data-end="}">
|
||
<div class="line"><a id="l00279" name="l00279"></a><span class="lineno"><a class="line" href="decls_8h.html#a7065a9fefcaabfecc4184528f01ef013"> 279</a></span><a class="code hl_define" href="decls_8h.html#a9001412c35f3c92d3a9320d27b0d97f9">AARU_EXPORT</a> <span class="keywordtype">void</span> <a class="code hl_define" href="decls_8h.html#a018e0da1c1f7e4f6187a982c0e40e056">AARU_CALL</a> *<a class="code hl_function" href="create_8c.html#a8fc1d6adf1ec5cc7d7bb9c067aff9f6e">aaruf_create</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *filepath, <span class="keyword">const</span> uint32_t media_type, <span class="keyword">const</span> uint32_t sector_size,</div>
|
||
<div class="line"><a id="l00280" name="l00280"></a><span class="lineno"> 280</span> <span class="keyword">const</span> uint64_t user_sectors, <span class="keyword">const</span> uint64_t negative_sectors,</div>
|
||
<div class="line"><a id="l00281" name="l00281"></a><span class="lineno"> 281</span> <span class="keyword">const</span> uint64_t overflow_sectors, <span class="keyword">const</span> <span class="keywordtype">char</span> *options,</div>
|
||
<div class="line"><a id="l00282" name="l00282"></a><span class="lineno"> 282</span> <span class="keyword">const</span> uint8_t *application_name, <span class="keyword">const</span> uint8_t application_name_length,</div>
|
||
<div class="line"><a id="l00283" name="l00283"></a><span class="lineno"> 283</span> <span class="keyword">const</span> uint8_t application_major_version,</div>
|
||
<div class="line"><a id="l00284" name="l00284"></a><span class="lineno"> 284</span> <span class="keyword">const</span> uint8_t application_minor_version, <span class="keyword">const</span> <span class="keywordtype">bool</span> is_tape)</div>
|
||
<div class="line"><a id="l00285" name="l00285"></a><span class="lineno"> 285</span>{</div>
|
||
<div class="line"><a id="l00286" name="l00286"></a><span class="lineno"> 286</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Entering aaruf_create(%s, %u, %u, %llu, %llu, %llu, %s, %s, %u, %u, %u, %d)"</span>, filepath, media_type,</div>
|
||
<div class="line"><a id="l00287" name="l00287"></a><span class="lineno"> 287</span> sector_size, user_sectors, negative_sectors, overflow_sectors, options,</div>
|
||
<div class="line"><a id="l00288" name="l00288"></a><span class="lineno"> 288</span> application_name ? (<span class="keyword">const</span> <span class="keywordtype">char</span> *)application_name : <span class="stringliteral">"NULL"</span>, application_name_length,</div>
|
||
<div class="line"><a id="l00289" name="l00289"></a><span class="lineno"> 289</span> application_major_version, application_minor_version, is_tape);</div>
|
||
<div class="line"><a id="l00290" name="l00290"></a><span class="lineno"> 290</span> </div>
|
||
<div class="line"><a id="l00291" name="l00291"></a><span class="lineno"> 291</span> <span class="comment">// Parse the options</span></div>
|
||
<div class="line"><a id="l00292" name="l00292"></a><span class="lineno"> 292</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Parsing options"</span>);</div>
|
||
<div class="line"><a id="l00293" name="l00293"></a><span class="lineno"> 293</span> <span class="keyword">const</span> <a class="code hl_struct" href="structaaru__options.html">aaru_options</a> parsed_options = <a class="code hl_function" href="internal_8h.html#aaae42bff244df727b6c029f58d4957df">parse_options</a>(options);</div>
|
||
<div class="line"><a id="l00294" name="l00294"></a><span class="lineno"> 294</span> </div>
|
||
<div class="line"><a id="l00295" name="l00295"></a><span class="lineno"> 295</span> <span class="comment">// Allocate context</span></div>
|
||
<div class="line"><a id="l00296" name="l00296"></a><span class="lineno"> 296</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Allocating memory for context"</span>);</div>
|
||
<div class="line"><a id="l00297" name="l00297"></a><span class="lineno"> 297</span> <a class="code hl_struct" href="structaaruformat__context.html">aaruformat_context</a> *ctx = malloc(<span class="keyword">sizeof</span>(<a class="code hl_struct" href="structaaruformat__context.html">aaruformat_context</a>));</div>
|
||
<div class="line"><a id="l00298" name="l00298"></a><span class="lineno"> 298</span> <span class="keywordflow">if</span>(ctx == NULL)</div>
|
||
<div class="line"><a id="l00299" name="l00299"></a><span class="lineno"> 299</span> {</div>
|
||
<div class="line"><a id="l00300" name="l00300"></a><span class="lineno"> 300</span> <a class="code hl_define" href="log_8h.html#a053d6037d543b84ce59308ce71d15cd1">FATAL</a>(<span class="stringliteral">"Not enough memory to create context"</span>);</div>
|
||
<div class="line"><a id="l00301" name="l00301"></a><span class="lineno"> 301</span> errno = <a class="code hl_define" href="errors_8h.html#a35a771e3648bf971a004d4b2be9b5ec4">AARUF_ERROR_NOT_ENOUGH_MEMORY</a>;</div>
|
||
<div class="line"><a id="l00302" name="l00302"></a><span class="lineno"> 302</span> </div>
|
||
<div class="line"><a id="l00303" name="l00303"></a><span class="lineno"> 303</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Exiting aaruf_create() = NULL"</span>);</div>
|
||
<div class="line"><a id="l00304" name="l00304"></a><span class="lineno"> 304</span> <span class="keywordflow">return</span> NULL;</div>
|
||
<div class="line"><a id="l00305" name="l00305"></a><span class="lineno"> 305</span> }</div>
|
||
<div class="line"><a id="l00306" name="l00306"></a><span class="lineno"> 306</span> </div>
|
||
<div class="line"><a id="l00307" name="l00307"></a><span class="lineno"> 307</span> memset(ctx, 0, <span class="keyword">sizeof</span>(<a class="code hl_struct" href="structaaruformat__context.html">aaruformat_context</a>));</div>
|
||
<div class="line"><a id="l00308" name="l00308"></a><span class="lineno"> 308</span> </div>
|
||
<div class="line"><a id="l00309" name="l00309"></a><span class="lineno"> 309</span> <span class="comment">// Create the image file</span></div>
|
||
<div class="line"><a id="l00310" name="l00310"></a><span class="lineno"> 310</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Creating image file %s"</span>, filepath);</div>
|
||
<div class="line"><a id="l00311" name="l00311"></a><span class="lineno"> 311</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab516fae594bde4f76b75488d0a3ca3a8">imageStream</a> = fopen(filepath, <span class="stringliteral">"wb+"</span>);</div>
|
||
<div class="line"><a id="l00312" name="l00312"></a><span class="lineno"> 312</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab516fae594bde4f76b75488d0a3ca3a8">imageStream</a> == NULL)</div>
|
||
<div class="line"><a id="l00313" name="l00313"></a><span class="lineno"> 313</span> {</div>
|
||
<div class="line"><a id="l00314" name="l00314"></a><span class="lineno"> 314</span> <a class="code hl_define" href="log_8h.html#a053d6037d543b84ce59308ce71d15cd1">FATAL</a>(<span class="stringliteral">"Error %d opening file %s for writing"</span>, errno, filepath);</div>
|
||
<div class="line"><a id="l00315" name="l00315"></a><span class="lineno"> 315</span> errno = <a class="code hl_define" href="errors_8h.html#a05c6aa0d46349e5060d75d5b6308d1e3">AARUF_ERROR_CANNOT_CREATE_FILE</a>;</div>
|
||
<div class="line"><a id="l00316" name="l00316"></a><span class="lineno"> 316</span> </div>
|
||
<div class="line"><a id="l00317" name="l00317"></a><span class="lineno"> 317</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Exiting aaruf_create() = NULL"</span>);</div>
|
||
<div class="line"><a id="l00318" name="l00318"></a><span class="lineno"> 318</span> <a class="code hl_function" href="create_8c.html#ae92275e097d4193d960bb97311b9cd78">cleanup_failed_create</a>(ctx);</div>
|
||
<div class="line"><a id="l00319" name="l00319"></a><span class="lineno"> 319</span> <span class="keywordflow">return</span> NULL;</div>
|
||
<div class="line"><a id="l00320" name="l00320"></a><span class="lineno"> 320</span> }</div>
|
||
<div class="line"><a id="l00321" name="l00321"></a><span class="lineno"> 321</span> </div>
|
||
<div class="line"><a id="l00322" name="l00322"></a><span class="lineno"> 322</span> <span class="keywordflow">if</span>(application_name_length > <a class="code hl_define" href="header_8h.html#ab17964dacc36dca03ec5e75aa40a4502">AARU_HEADER_APP_NAME_LEN</a>)</div>
|
||
<div class="line"><a id="l00323" name="l00323"></a><span class="lineno"> 323</span> {</div>
|
||
<div class="line"><a id="l00324" name="l00324"></a><span class="lineno"> 324</span> <a class="code hl_define" href="log_8h.html#a053d6037d543b84ce59308ce71d15cd1">FATAL</a>(<span class="stringliteral">"Application name too long (%u bytes, maximum %u bytes)"</span>, application_name_length,</div>
|
||
<div class="line"><a id="l00325" name="l00325"></a><span class="lineno"> 325</span> <a class="code hl_define" href="header_8h.html#ab17964dacc36dca03ec5e75aa40a4502">AARU_HEADER_APP_NAME_LEN</a>);</div>
|
||
<div class="line"><a id="l00326" name="l00326"></a><span class="lineno"> 326</span> errno = <a class="code hl_define" href="errors_8h.html#a24494b154606028b04c1d71367545e5c">AARUF_ERROR_INVALID_APP_NAME_LENGTH</a>;</div>
|
||
<div class="line"><a id="l00327" name="l00327"></a><span class="lineno"> 327</span> </div>
|
||
<div class="line"><a id="l00328" name="l00328"></a><span class="lineno"> 328</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Exiting aaruf_create() = NULL"</span>);</div>
|
||
<div class="line"><a id="l00329" name="l00329"></a><span class="lineno"> 329</span> <a class="code hl_function" href="create_8c.html#ae92275e097d4193d960bb97311b9cd78">cleanup_failed_create</a>(ctx);</div>
|
||
<div class="line"><a id="l00330" name="l00330"></a><span class="lineno"> 330</span> <span class="keywordflow">return</span> NULL;</div>
|
||
<div class="line"><a id="l00331" name="l00331"></a><span class="lineno"> 331</span> }</div>
|
||
<div class="line"><a id="l00332" name="l00332"></a><span class="lineno"> 332</span> </div>
|
||
<div class="line"><a id="l00333" name="l00333"></a><span class="lineno"> 333</span> <span class="comment">// Initialize header</span></div>
|
||
<div class="line"><a id="l00334" name="l00334"></a><span class="lineno"> 334</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Initializing header"</span>);</div>
|
||
<div class="line"><a id="l00335" name="l00335"></a><span class="lineno"> 335</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a27af1bfabbc7650471a6010475116697">identifier</a> = <a class="code hl_define" href="consts_8h.html#a3c3ba66fe2b547655c9e4b16a1ba519a">AARU_MAGIC</a>;</div>
|
||
<div class="line"><a id="l00336" name="l00336"></a><span class="lineno"> 336</span> memcpy(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a0afcf9a5f565a9053351f44234c90dc3">application</a>, application_name, application_name_length);</div>
|
||
<div class="line"><a id="l00337" name="l00337"></a><span class="lineno"> 337</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#af79ca31bcd428d1a54ac25c30d09b7a7">imageMajorVersion</a> = <a class="code hl_define" href="consts_8h.html#ad2fdced5805aa0364f1c5b073f81dd76">AARUF_VERSION_V2</a>;</div>
|
||
<div class="line"><a id="l00338" name="l00338"></a><span class="lineno"> 338</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#ae2d6d3c7bc0a1956fb246cf7acbddeeb">imageMinorVersion</a> = 0;</div>
|
||
<div class="line"><a id="l00339" name="l00339"></a><span class="lineno"> 339</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a1c26feafd945328f8f1854b523a0f03c">applicationMajorVersion</a> = application_major_version;</div>
|
||
<div class="line"><a id="l00340" name="l00340"></a><span class="lineno"> 340</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a5ae79accbb8ba2762d01a63ad334ee60">applicationMinorVersion</a> = application_minor_version;</div>
|
||
<div class="line"><a id="l00341" name="l00341"></a><span class="lineno"> 341</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a81b114ab2b1fa786f64e9e914af3ba27">mediaType</a> = media_type;</div>
|
||
<div class="line"><a id="l00342" name="l00342"></a><span class="lineno"> 342</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a4ec4b1d593f5a0af19f6d7b8eaeada40">indexOffset</a> = 0;</div>
|
||
<div class="line"><a id="l00343" name="l00343"></a><span class="lineno"> 343</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#ae849dae5af5cf31b1b815ef67b3c621f">creationTime</a> = <a class="code hl_function" href="internal_8h.html#a36c1cca0e4cea9c2e0dffb582b836f6f">get_filetime_uint64</a>();</div>
|
||
<div class="line"><a id="l00344" name="l00344"></a><span class="lineno"> 344</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a45bc7e2afc9008ce6f4ae1dba93bdac3">lastWrittenTime</a> = <a class="code hl_function" href="internal_8h.html#a36c1cca0e4cea9c2e0dffb582b836f6f">get_filetime_uint64</a>();</div>
|
||
<div class="line"><a id="l00345" name="l00345"></a><span class="lineno"> 345</span> </div>
|
||
<div class="line"><a id="l00346" name="l00346"></a><span class="lineno"> 346</span> <span class="comment">// Generate random GUID for the image</span></div>
|
||
<div class="line"><a id="l00347" name="l00347"></a><span class="lineno"> 347</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Generating random GUID"</span>);</div>
|
||
<div class="line"><a id="l00348" name="l00348"></a><span class="lineno"> 348</span> <a class="code hl_function" href="internal_8h.html#a7db9f44b931877b306de9cf7cd1deed2">generate_random_bytes</a>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a69ff1a1dbdaf0501e6488451b7270b51">guid</a>, <a class="code hl_define" href="header_8h.html#a57c99b24137b82f12950e79ffbd2fb7a">GUID_SIZE</a>);</div>
|
||
<div class="line"><a id="l00349" name="l00349"></a><span class="lineno"> 349</span> </div>
|
||
<div class="line"><a id="l00350" name="l00350"></a><span class="lineno"> 350</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ad3d5494e23b07418e9fbd22c3771e534">readableSectorTags</a> = (<span class="keywordtype">bool</span> *)malloc(<span class="keyword">sizeof</span>(<span class="keywordtype">bool</span>) * <a class="code hl_enumvalue" href="group__SectorTags.html#ggaf863e81d172ce7a216d8687a8a23293aa81dbcd4677b6377bce5351ad92fc4d64">MaxSectorTag</a>);</div>
|
||
<div class="line"><a id="l00351" name="l00351"></a><span class="lineno"> 351</span> </div>
|
||
<div class="line"><a id="l00352" name="l00352"></a><span class="lineno"> 352</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ad3d5494e23b07418e9fbd22c3771e534">readableSectorTags</a> == NULL)</div>
|
||
<div class="line"><a id="l00353" name="l00353"></a><span class="lineno"> 353</span> {</div>
|
||
<div class="line"><a id="l00354" name="l00354"></a><span class="lineno"> 354</span> errno = <a class="code hl_define" href="errors_8h.html#a35a771e3648bf971a004d4b2be9b5ec4">AARUF_ERROR_NOT_ENOUGH_MEMORY</a>;</div>
|
||
<div class="line"><a id="l00355" name="l00355"></a><span class="lineno"> 355</span> </div>
|
||
<div class="line"><a id="l00356" name="l00356"></a><span class="lineno"> 356</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Exiting aaruf_create() = NULL"</span>);</div>
|
||
<div class="line"><a id="l00357" name="l00357"></a><span class="lineno"> 357</span> <a class="code hl_function" href="create_8c.html#ae92275e097d4193d960bb97311b9cd78">cleanup_failed_create</a>(ctx);</div>
|
||
<div class="line"><a id="l00358" name="l00358"></a><span class="lineno"> 358</span> <span class="keywordflow">return</span> NULL;</div>
|
||
<div class="line"><a id="l00359" name="l00359"></a><span class="lineno"> 359</span> }</div>
|
||
<div class="line"><a id="l00360" name="l00360"></a><span class="lineno"> 360</span> </div>
|
||
<div class="line"><a id="l00361" name="l00361"></a><span class="lineno"> 361</span> memset(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ad3d5494e23b07418e9fbd22c3771e534">readableSectorTags</a>, 0, <span class="keyword">sizeof</span>(<span class="keywordtype">bool</span>) * <a class="code hl_enumvalue" href="group__SectorTags.html#ggaf863e81d172ce7a216d8687a8a23293aa81dbcd4677b6377bce5351ad92fc4d64">MaxSectorTag</a>);</div>
|
||
<div class="line"><a id="l00362" name="l00362"></a><span class="lineno"> 362</span> </div>
|
||
<div class="line"><a id="l00363" name="l00363"></a><span class="lineno"> 363</span> <span class="comment">// Initialize image info</span></div>
|
||
<div class="line"><a id="l00364" name="l00364"></a><span class="lineno"> 364</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Initializing image info"</span>);</div>
|
||
<div class="line"><a id="l00365" name="l00365"></a><span class="lineno"> 365</span> </div>
|
||
<div class="line"><a id="l00366" name="l00366"></a><span class="lineno"> 366</span> <span class="comment">// Copy application name (UTF-8) to image_info</span></div>
|
||
<div class="line"><a id="l00367" name="l00367"></a><span class="lineno"> 367</span> memset(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#aaea8b3a14fc03f9a4b045318160b7f54">Application</a>, 0, 64);</div>
|
||
<div class="line"><a id="l00368" name="l00368"></a><span class="lineno"> 368</span> <span class="keywordtype">size_t</span> copy_len = application_name_length < 63 ? application_name_length : 63;</div>
|
||
<div class="line"><a id="l00369" name="l00369"></a><span class="lineno"> 369</span> memcpy(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#aaea8b3a14fc03f9a4b045318160b7f54">Application</a>, application_name, copy_len);</div>
|
||
<div class="line"><a id="l00370" name="l00370"></a><span class="lineno"> 370</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#aaea8b3a14fc03f9a4b045318160b7f54">Application</a>[63] = <span class="charliteral">'\0'</span>;</div>
|
||
<div class="line"><a id="l00371" name="l00371"></a><span class="lineno"> 371</span> </div>
|
||
<div class="line"><a id="l00372" name="l00372"></a><span class="lineno"> 372</span> <span class="comment">// Set application version string directly in the fixed-size array</span></div>
|
||
<div class="line"><a id="l00373" name="l00373"></a><span class="lineno"> 373</span> memset(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#aebf7783c46e640a8e7d0192ba2843e9a">ApplicationVersion</a>, 0, 32);</div>
|
||
<div class="line"><a id="l00374" name="l00374"></a><span class="lineno"> 374</span> sprintf(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#aebf7783c46e640a8e7d0192ba2843e9a">ApplicationVersion</a>, <span class="stringliteral">"%d.%d"</span>, ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a1c26feafd945328f8f1854b523a0f03c">applicationMajorVersion</a>,</div>
|
||
<div class="line"><a id="l00375" name="l00375"></a><span class="lineno"> 375</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a5ae79accbb8ba2762d01a63ad334ee60">applicationMinorVersion</a>);</div>
|
||
<div class="line"><a id="l00376" name="l00376"></a><span class="lineno"> 376</span> </div>
|
||
<div class="line"><a id="l00377" name="l00377"></a><span class="lineno"> 377</span> <span class="comment">// Set image version string directly in the fixed-size array</span></div>
|
||
<div class="line"><a id="l00378" name="l00378"></a><span class="lineno"> 378</span> memset(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#adce978941d9900c8c05e620df67f8c5c">Version</a>, 0, 32);</div>
|
||
<div class="line"><a id="l00379" name="l00379"></a><span class="lineno"> 379</span> sprintf(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#adce978941d9900c8c05e620df67f8c5c">Version</a>, <span class="stringliteral">"%d.%d"</span>, ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#af79ca31bcd428d1a54ac25c30d09b7a7">imageMajorVersion</a>, ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#ae2d6d3c7bc0a1956fb246cf7acbddeeb">imageMinorVersion</a>);</div>
|
||
<div class="line"><a id="l00380" name="l00380"></a><span class="lineno"> 380</span> </div>
|
||
<div class="line"><a id="l00381" name="l00381"></a><span class="lineno"> 381</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#a76611d5087e0a9fd4d329fac7c9ec3f3">MediaType</a> = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a81b114ab2b1fa786f64e9e914af3ba27">mediaType</a>;</div>
|
||
<div class="line"><a id="l00382" name="l00382"></a><span class="lineno"> 382</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#abca8e73a9655d810e6d30d36c3ab54d7">ImageSize</a> = 0;</div>
|
||
<div class="line"><a id="l00383" name="l00383"></a><span class="lineno"> 383</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#acbccd97dbc139ed2f81d9997560725bb">CreationTime</a> = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#ae849dae5af5cf31b1b815ef67b3c621f">creationTime</a>;</div>
|
||
<div class="line"><a id="l00384" name="l00384"></a><span class="lineno"> 384</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#ada8567fee9fbe636cb10f788b3705e3a">LastModificationTime</a> = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a45bc7e2afc9008ce6f4ae1dba93bdac3">lastWrittenTime</a>;</div>
|
||
<div class="line"><a id="l00385" name="l00385"></a><span class="lineno"> 385</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#a7ed25efcf8cec55d6609b83bcd17b2d0">MetadataMediaType</a> = <a class="code hl_function" href="decls_8h.html#ac5f5334a51424028574a5433a0e24b20">aaruf_get_xml_mediatype</a>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">header</a>.<a class="code hl_variable" href="structAaruHeaderV2.html#a81b114ab2b1fa786f64e9e914af3ba27">mediaType</a>);</div>
|
||
<div class="line"><a id="l00386" name="l00386"></a><span class="lineno"> 386</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#aac1ac48f57afd415467cd6f13f01644b">SectorSize</a> = sector_size;</div>
|
||
<div class="line"><a id="l00387" name="l00387"></a><span class="lineno"> 387</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#ae3e1b9cde1c51152b00eb1b59e199906">Sectors</a> = user_sectors;</div>
|
||
<div class="line"><a id="l00388" name="l00388"></a><span class="lineno"> 388</span> </div>
|
||
<div class="line"><a id="l00389" name="l00389"></a><span class="lineno"> 389</span> <span class="comment">// Initialize caches</span></div>
|
||
<div class="line"><a id="l00390" name="l00390"></a><span class="lineno"> 390</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Initializing caches"</span>);</div>
|
||
<div class="line"><a id="l00391" name="l00391"></a><span class="lineno"> 391</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3a12addf4a338cc04471709604d48ae1">block_header_cache</a>.<a class="code hl_variable" href="structCacheHeader.html#a44229bb929d8949f3c2700d07123d224">cache</a> = NULL;</div>
|
||
<div class="line"><a id="l00392" name="l00392"></a><span class="lineno"> 392</span> <span class="keyword">const</span> uint64_t cache_divisor = (uint64_t)ctx-><a class="code hl_variable" href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">image_info</a>.<a class="code hl_variable" href="structImageInfo.html#aac1ac48f57afd415467cd6f13f01644b">SectorSize</a> * (1ULL << ctx-><a class="code hl_variable" href="structaaruformat__context.html#a4023f622bac759754c68ac633c53e3f4">shift</a>);</div>
|
||
<div class="line"><a id="l00393" name="l00393"></a><span class="lineno"> 393</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3a12addf4a338cc04471709604d48ae1">block_header_cache</a>.<a class="code hl_variable" href="structCacheHeader.html#ad3b962f8ce6c6115143cf581c7936e55">max_items</a> = cache_divisor == 0 ? 0 : <a class="code hl_define" href="consts_8h.html#a6c8469dfe973ac952cf40394bd2c160b">MAX_CACHE_SIZE</a> / cache_divisor;</div>
|
||
<div class="line"><a id="l00394" name="l00394"></a><span class="lineno"> 394</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a58359ec8607d1d10e0af8699be238e77">block_cache</a>.<a class="code hl_variable" href="structCacheHeader.html#a44229bb929d8949f3c2700d07123d224">cache</a> = NULL;</div>
|
||
<div class="line"><a id="l00395" name="l00395"></a><span class="lineno"> 395</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a58359ec8607d1d10e0af8699be238e77">block_cache</a>.<a class="code hl_variable" href="structCacheHeader.html#ad3b962f8ce6c6115143cf581c7936e55">max_items</a> = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3a12addf4a338cc04471709604d48ae1">block_header_cache</a>.<a class="code hl_variable" href="structCacheHeader.html#ad3b962f8ce6c6115143cf581c7936e55">max_items</a>;</div>
|
||
<div class="line"><a id="l00396" name="l00396"></a><span class="lineno"> 396</span> </div>
|
||
<div class="line"><a id="l00397" name="l00397"></a><span class="lineno"> 397</span> <span class="comment">// TODO: Cache tracks and sessions?</span></div>
|
||
<div class="line"><a id="l00398" name="l00398"></a><span class="lineno"> 398</span> </div>
|
||
<div class="line"><a id="l00399" name="l00399"></a><span class="lineno"> 399</span> <span class="comment">// Initialize ECC for Compact Disc</span></div>
|
||
<div class="line"><a id="l00400" name="l00400"></a><span class="lineno"> 400</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Initializing Compact Disc ECC"</span>);</div>
|
||
<div class="line"><a id="l00401" name="l00401"></a><span class="lineno"> 401</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a510b72290e2bd50e02ef8a2387aa829d">ecc_cd_context</a> = (<a class="code hl_struct" href="structCdEccContext.html">CdEccContext</a> *)<a class="code hl_function" href="decls_8h.html#ac1a30bb251ac148f485c51593c0740c1">aaruf_ecc_cd_init</a>();</div>
|
||
<div class="line"><a id="l00402" name="l00402"></a><span class="lineno"> 402</span> </div>
|
||
<div class="line"><a id="l00403" name="l00403"></a><span class="lineno"> 403</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a7dc0a0fe0bf6223ff4587fd01c360b76">magic</a> = <a class="code hl_define" href="consts_8h.html#a3c3ba66fe2b547655c9e4b16a1ba519a">AARU_MAGIC</a>;</div>
|
||
<div class="line"><a id="l00404" name="l00404"></a><span class="lineno"> 404</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a09177c9e68d054bab844305f2771b77a">library_major_version</a> = <a class="code hl_define" href="aaruformat_8h.html#a1341a1043d24b7d7e234fcbfe52dd907">LIBAARUFORMAT_MAJOR_VERSION</a>;</div>
|
||
<div class="line"><a id="l00405" name="l00405"></a><span class="lineno"> 405</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a8fb7db933d8abfeb20a28110cb258922">library_minor_version</a> = <a class="code hl_define" href="aaruformat_8h.html#a9258501500f40e275641fca951a3ce04">LIBAARUFORMAT_MINOR_VERSION</a>;</div>
|
||
<div class="line"><a id="l00406" name="l00406"></a><span class="lineno"> 406</span> </div>
|
||
<div class="line"><a id="l00407" name="l00407"></a><span class="lineno"> 407</span> <span class="keywordflow">if</span>(!is_tape)</div>
|
||
<div class="line"><a id="l00408" name="l00408"></a><span class="lineno"> 408</span> { <span class="comment">// Initialize DDT2</span></div>
|
||
<div class="line"><a id="l00409" name="l00409"></a><span class="lineno"> 409</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Initializing DDT2"</span>);</div>
|
||
<div class="line"><a id="l00410" name="l00410"></a><span class="lineno"> 410</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a62885cab6ef674fd27b4de32ab4ee346">in_memory_ddt</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00411" name="l00411"></a><span class="lineno"> 411</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a80a88ec68cd0332a57886ac363bfa4d1">identifier</a> = <a class="code hl_enumvalue" href="enums_8h.html#a54420623f26ab6bb61042b41cccf37a3aba4d0f50b26af1d0292daaa0d70feacf">DeDuplicationTable2</a>;</div>
|
||
<div class="line"><a id="l00412" name="l00412"></a><span class="lineno"> 412</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a14f9ccf36df63e036d69291182cf7bbb">type</a> = <a class="code hl_enumvalue" href="enums_8h.html#ad8ed01ff3ff33333d8e19db4d2818bb6a73bb26133ccd01972725933b00ec3a06">UserData</a>;</div>
|
||
<div class="line"><a id="l00413" name="l00413"></a><span class="lineno"> 413</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#ad1a27a46df09748a91a9010a630c422e">compression</a> = <a class="code hl_enumvalue" href="enums_8h.html#affec749ed88365143745313ae9168263ac9d3e887722f2bc482bcca9d41c512af">None</a>;</div>
|
||
<div class="line"><a id="l00414" name="l00414"></a><span class="lineno"> 414</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#ac8ec7921a5651b5107eda4e99b488798">tableLevel</a> = 0;</div>
|
||
<div class="line"><a id="l00415" name="l00415"></a><span class="lineno"> 415</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#af71423c2a8c7fa89dfd2313b456c57a2">previousLevelOffset</a> = 0;</div>
|
||
<div class="line"><a id="l00416" name="l00416"></a><span class="lineno"> 416</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#aa4b1416ac0e0585f436513cacf9ebd74">negative</a> = negative_sectors;</div>
|
||
<div class="line"><a id="l00417" name="l00417"></a><span class="lineno"> 417</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a9571c1d556e33537935bab1edba31135">blocks</a> = user_sectors + overflow_sectors + negative_sectors;</div>
|
||
<div class="line"><a id="l00418" name="l00418"></a><span class="lineno"> 418</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a2bfa558d9d778ae6b86d52520e278b66">overflow</a> = overflow_sectors;</div>
|
||
<div class="line"><a id="l00419" name="l00419"></a><span class="lineno"> 419</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a238a2ca31ce0f60af3e59a1cb3e2e73c">start</a> = 0;</div>
|
||
<div class="line"><a id="l00420" name="l00420"></a><span class="lineno"> 420</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#aa67b097c3a20f926ede495d27152f1c0">blockAlignmentShift</a> = parsed_options.<a class="code hl_variable" href="structaaru__options.html#aea2e536712f73ad12dcca704b47dc48c">block_alignment</a>;</div>
|
||
<div class="line"><a id="l00421" name="l00421"></a><span class="lineno"> 421</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#ad9a2beb3a79bc6c239ba04fe341e0cde">dataShift</a> = parsed_options.<a class="code hl_variable" href="structaaru__options.html#a3b6341d5cbd1ed2c4ff0686cd88de753">data_shift</a>;</div>
|
||
<div class="line"><a id="l00422" name="l00422"></a><span class="lineno"> 422</span> </div>
|
||
<div class="line"><a id="l00423" name="l00423"></a><span class="lineno"> 423</span> <span class="keywordflow">if</span>(parsed_options.<a class="code hl_variable" href="structaaru__options.html#a8b82ce71c52cc737f7b73334e094a795">table_shift</a> == -1)</div>
|
||
<div class="line"><a id="l00424" name="l00424"></a><span class="lineno"> 424</span> {</div>
|
||
<div class="line"><a id="l00425" name="l00425"></a><span class="lineno"> 425</span> <span class="keyword">const</span> uint64_t total_sectors = user_sectors + overflow_sectors + negative_sectors;</div>
|
||
<div class="line"><a id="l00426" name="l00426"></a><span class="lineno"> 426</span> </div>
|
||
<div class="line"><a id="l00427" name="l00427"></a><span class="lineno"> 427</span> <span class="keywordflow">if</span>(total_sectors < 0x8388608ULL)</div>
|
||
<div class="line"><a id="l00428" name="l00428"></a><span class="lineno"> 428</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a8c2110cbb42bde3c0e302d3429024b04">tableShift</a> = 0;</div>
|
||
<div class="line"><a id="l00429" name="l00429"></a><span class="lineno"> 429</span> <span class="keywordflow">else</span></div>
|
||
<div class="line"><a id="l00430" name="l00430"></a><span class="lineno"> 430</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a8c2110cbb42bde3c0e302d3429024b04">tableShift</a> = 22;</div>
|
||
<div class="line"><a id="l00431" name="l00431"></a><span class="lineno"> 431</span> }</div>
|
||
<div class="line"><a id="l00432" name="l00432"></a><span class="lineno"> 432</span> <span class="keywordflow">else</span></div>
|
||
<div class="line"><a id="l00433" name="l00433"></a><span class="lineno"> 433</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a8c2110cbb42bde3c0e302d3429024b04">tableShift</a> =</div>
|
||
<div class="line"><a id="l00434" name="l00434"></a><span class="lineno"> 434</span> parsed_options.<a class="code hl_variable" href="structaaru__options.html#a8b82ce71c52cc737f7b73334e094a795">table_shift</a> > 0 ? (uint8_t)parsed_options.<a class="code hl_variable" href="structaaru__options.html#a8b82ce71c52cc737f7b73334e094a795">table_shift</a> : 0;</div>
|
||
<div class="line"><a id="l00435" name="l00435"></a><span class="lineno"> 435</span> </div>
|
||
<div class="line"><a id="l00436" name="l00436"></a><span class="lineno"> 436</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a68f4825db4e22906af0e55a359360656">levels</a> = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a8c2110cbb42bde3c0e302d3429024b04">tableShift</a> > 0 ? 2 : 1;</div>
|
||
<div class="line"><a id="l00437" name="l00437"></a><span class="lineno"> 437</span> </div>
|
||
<div class="line"><a id="l00438" name="l00438"></a><span class="lineno"> 438</span> uint8_t effective_table_shift = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a8c2110cbb42bde3c0e302d3429024b04">tableShift</a>;</div>
|
||
<div class="line"><a id="l00439" name="l00439"></a><span class="lineno"> 439</span> <span class="keywordflow">if</span>(effective_table_shift >= 63)</div>
|
||
<div class="line"><a id="l00440" name="l00440"></a><span class="lineno"> 440</span> {</div>
|
||
<div class="line"><a id="l00441" name="l00441"></a><span class="lineno"> 441</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Clamping table shift from %u to 62 to avoid overflow"</span>, effective_table_shift);</div>
|
||
<div class="line"><a id="l00442" name="l00442"></a><span class="lineno"> 442</span> effective_table_shift = 62;</div>
|
||
<div class="line"><a id="l00443" name="l00443"></a><span class="lineno"> 443</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a8c2110cbb42bde3c0e302d3429024b04">tableShift</a> = effective_table_shift;</div>
|
||
<div class="line"><a id="l00444" name="l00444"></a><span class="lineno"> 444</span> }</div>
|
||
<div class="line"><a id="l00445" name="l00445"></a><span class="lineno"> 445</span> </div>
|
||
<div class="line"><a id="l00446" name="l00446"></a><span class="lineno"> 446</span> <span class="keyword">const</span> uint64_t sectors_per_entry = 1ULL << effective_table_shift;</div>
|
||
<div class="line"><a id="l00447" name="l00447"></a><span class="lineno"> 447</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a4e90c22109c3fff37b526a113b094a50">entries</a> = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a9571c1d556e33537935bab1edba31135">blocks</a> / sectors_per_entry;</div>
|
||
<div class="line"><a id="l00448" name="l00448"></a><span class="lineno"> 448</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a9571c1d556e33537935bab1edba31135">blocks</a> % sectors_per_entry != 0 || ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a4e90c22109c3fff37b526a113b094a50">entries</a> == 0)</div>
|
||
<div class="line"><a id="l00449" name="l00449"></a><span class="lineno"> 449</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a4e90c22109c3fff37b526a113b094a50">entries</a>++;</div>
|
||
<div class="line"><a id="l00450" name="l00450"></a><span class="lineno"> 450</span> </div>
|
||
<div class="line"><a id="l00451" name="l00451"></a><span class="lineno"> 451</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Initializing primary/single DDT"</span>);</div>
|
||
<div class="line"><a id="l00452" name="l00452"></a><span class="lineno"> 452</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3c7b902731274622296d04564b193b64">user_data_ddt2</a> =</div>
|
||
<div class="line"><a id="l00453" name="l00453"></a><span class="lineno"> 453</span> (uint64_t *)calloc(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a4e90c22109c3fff37b526a113b094a50">entries</a>, <span class="keyword">sizeof</span>(uint64_t)); <span class="comment">// All entries to zero</span></div>
|
||
<div class="line"><a id="l00454" name="l00454"></a><span class="lineno"> 454</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3c7b902731274622296d04564b193b64">user_data_ddt2</a> == NULL)</div>
|
||
<div class="line"><a id="l00455" name="l00455"></a><span class="lineno"> 455</span> {</div>
|
||
<div class="line"><a id="l00456" name="l00456"></a><span class="lineno"> 456</span> <a class="code hl_define" href="log_8h.html#a053d6037d543b84ce59308ce71d15cd1">FATAL</a>(<span class="stringliteral">"Not enough memory to allocate primary DDT (big)"</span>);</div>
|
||
<div class="line"><a id="l00457" name="l00457"></a><span class="lineno"> 457</span> errno = <a class="code hl_define" href="errors_8h.html#a35a771e3648bf971a004d4b2be9b5ec4">AARUF_ERROR_NOT_ENOUGH_MEMORY</a>;</div>
|
||
<div class="line"><a id="l00458" name="l00458"></a><span class="lineno"> 458</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Exiting aaruf_create() = NULL"</span>);</div>
|
||
<div class="line"><a id="l00459" name="l00459"></a><span class="lineno"> 459</span> <a class="code hl_function" href="create_8c.html#ae92275e097d4193d960bb97311b9cd78">cleanup_failed_create</a>(ctx);</div>
|
||
<div class="line"><a id="l00460" name="l00460"></a><span class="lineno"> 460</span> <span class="keywordflow">return</span> NULL;</div>
|
||
<div class="line"><a id="l00461" name="l00461"></a><span class="lineno"> 461</span> }</div>
|
||
<div class="line"><a id="l00462" name="l00462"></a><span class="lineno"> 462</span> </div>
|
||
<div class="line"><a id="l00463" name="l00463"></a><span class="lineno"> 463</span> <span class="comment">// Set the primary DDT offset (just after the header, block aligned)</span></div>
|
||
<div class="line"><a id="l00464" name="l00464"></a><span class="lineno"> 464</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a88effb2eb082320b5b31d729981cf2d4">primary_ddt_offset</a> = <span class="keyword">sizeof</span>(<a class="code hl_struct" href="structAaruHeaderV2.html">AaruHeaderV2</a>); <span class="comment">// Start just after the header</span></div>
|
||
<div class="line"><a id="l00465" name="l00465"></a><span class="lineno"> 465</span> <span class="keyword">const</span> uint64_t alignment_mask = (1ULL << ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#aa67b097c3a20f926ede495d27152f1c0">blockAlignmentShift</a>) - 1;</div>
|
||
<div class="line"><a id="l00466" name="l00466"></a><span class="lineno"> 466</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a88effb2eb082320b5b31d729981cf2d4">primary_ddt_offset</a> = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a88effb2eb082320b5b31d729981cf2d4">primary_ddt_offset</a> + alignment_mask & ~alignment_mask;</div>
|
||
<div class="line"><a id="l00467" name="l00467"></a><span class="lineno"> 467</span> </div>
|
||
<div class="line"><a id="l00468" name="l00468"></a><span class="lineno"> 468</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Primary DDT will be placed at offset %"</span> PRIu64, ctx-><a class="code hl_variable" href="structaaruformat__context.html#a88effb2eb082320b5b31d729981cf2d4">primary_ddt_offset</a>);</div>
|
||
<div class="line"><a id="l00469" name="l00469"></a><span class="lineno"> 469</span> </div>
|
||
<div class="line"><a id="l00470" name="l00470"></a><span class="lineno"> 470</span> <span class="comment">// Calculate size of primary DDT table</span></div>
|
||
<div class="line"><a id="l00471" name="l00471"></a><span class="lineno"> 471</span> <span class="keyword">const</span> uint64_t primary_table_size = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a4e90c22109c3fff37b526a113b094a50">entries</a> * <span class="keyword">sizeof</span>(uint64_t);</div>
|
||
<div class="line"><a id="l00472" name="l00472"></a><span class="lineno"> 472</span> </div>
|
||
<div class="line"><a id="l00473" name="l00473"></a><span class="lineno"> 473</span> <span class="comment">// Calculate where data blocks can start (after primary DDT + header)</span></div>
|
||
<div class="line"><a id="l00474" name="l00474"></a><span class="lineno"> 474</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a8c2110cbb42bde3c0e302d3429024b04">tableShift</a> > 0)</div>
|
||
<div class="line"><a id="l00475" name="l00475"></a><span class="lineno"> 475</span> {</div>
|
||
<div class="line"><a id="l00476" name="l00476"></a><span class="lineno"> 476</span> <span class="keyword">const</span> uint64_t data_start_position = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a88effb2eb082320b5b31d729981cf2d4">primary_ddt_offset</a> + <span class="keyword">sizeof</span>(<a class="code hl_struct" href="structDdtHeader2.html">DdtHeader2</a>) + primary_table_size;</div>
|
||
<div class="line"><a id="l00477" name="l00477"></a><span class="lineno"> 477</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a939b702f75e80062bc635add4c3ab142">next_block_position</a> = data_start_position + alignment_mask & ~alignment_mask;</div>
|
||
<div class="line"><a id="l00478" name="l00478"></a><span class="lineno"> 478</span> }</div>
|
||
<div class="line"><a id="l00479" name="l00479"></a><span class="lineno"> 479</span> <span class="keywordflow">else</span></div>
|
||
<div class="line"><a id="l00480" name="l00480"></a><span class="lineno"> 480</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a939b702f75e80062bc635add4c3ab142">next_block_position</a> = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a88effb2eb082320b5b31d729981cf2d4">primary_ddt_offset</a>; <span class="comment">// Single-level DDT can start anywhere</span></div>
|
||
<div class="line"><a id="l00481" name="l00481"></a><span class="lineno"> 481</span> }</div>
|
||
<div class="line"><a id="l00482" name="l00482"></a><span class="lineno"> 482</span> <span class="keywordflow">else</span></div>
|
||
<div class="line"><a id="l00483" name="l00483"></a><span class="lineno"> 483</span> {</div>
|
||
<div class="line"><a id="l00484" name="l00484"></a><span class="lineno"> 484</span> <span class="comment">// Fill needed values</span></div>
|
||
<div class="line"><a id="l00485" name="l00485"></a><span class="lineno"> 485</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#aa67b097c3a20f926ede495d27152f1c0">blockAlignmentShift</a> = parsed_options.<a class="code hl_variable" href="structaaru__options.html#aea2e536712f73ad12dcca704b47dc48c">block_alignment</a>;</div>
|
||
<div class="line"><a id="l00486" name="l00486"></a><span class="lineno"> 486</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#ad9a2beb3a79bc6c239ba04fe341e0cde">dataShift</a> = parsed_options.<a class="code hl_variable" href="structaaru__options.html#a3b6341d5cbd1ed2c4ff0686cd88de753">data_shift</a>;</div>
|
||
<div class="line"><a id="l00487" name="l00487"></a><span class="lineno"> 487</span> </div>
|
||
<div class="line"><a id="l00488" name="l00488"></a><span class="lineno"> 488</span> <span class="comment">// Calculate aligned next block position</span></div>
|
||
<div class="line"><a id="l00489" name="l00489"></a><span class="lineno"> 489</span> <span class="keyword">const</span> uint64_t alignment_mask = (1ULL << parsed_options.<a class="code hl_variable" href="structaaru__options.html#aea2e536712f73ad12dcca704b47dc48c">block_alignment</a>) - 1;</div>
|
||
<div class="line"><a id="l00490" name="l00490"></a><span class="lineno"> 490</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a939b702f75e80062bc635add4c3ab142">next_block_position</a> = <span class="keyword">sizeof</span>(<a class="code hl_struct" href="structAaruHeaderV2.html">AaruHeaderV2</a>); <span class="comment">// Start just after the header</span></div>
|
||
<div class="line"><a id="l00491" name="l00491"></a><span class="lineno"> 491</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a939b702f75e80062bc635add4c3ab142">next_block_position</a> = ctx-><a class="code hl_variable" href="structaaruformat__context.html#a939b702f75e80062bc635add4c3ab142">next_block_position</a> + alignment_mask & ~alignment_mask;</div>
|
||
<div class="line"><a id="l00492" name="l00492"></a><span class="lineno"> 492</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a4d514102386b48bd51ac82c27bf9920a">is_tape</a> = 1;</div>
|
||
<div class="line"><a id="l00493" name="l00493"></a><span class="lineno"> 493</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a705ef2714c4773514c23a56371f42a0f">tape_ddt</a> = NULL;</div>
|
||
<div class="line"><a id="l00494" name="l00494"></a><span class="lineno"> 494</span> }</div>
|
||
<div class="line"><a id="l00495" name="l00495"></a><span class="lineno"> 495</span> </div>
|
||
<div class="line"><a id="l00496" name="l00496"></a><span class="lineno"> 496</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Data blocks will start at position %"</span> PRIu64, ctx-><a class="code hl_variable" href="structaaruformat__context.html#a939b702f75e80062bc635add4c3ab142">next_block_position</a>);</div>
|
||
<div class="line"><a id="l00497" name="l00497"></a><span class="lineno"> 497</span> </div>
|
||
<div class="line"><a id="l00498" name="l00498"></a><span class="lineno"> 498</span> <span class="comment">// Position file pointer at the data start position</span></div>
|
||
<div class="line"><a id="l00499" name="l00499"></a><span class="lineno"> 499</span> <span class="keywordflow">if</span>(fseek(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab516fae594bde4f76b75488d0a3ca3a8">imageStream</a>, ctx-><a class="code hl_variable" href="structaaruformat__context.html#a939b702f75e80062bc635add4c3ab142">next_block_position</a>, SEEK_SET) != 0)</div>
|
||
<div class="line"><a id="l00500" name="l00500"></a><span class="lineno"> 500</span> {</div>
|
||
<div class="line"><a id="l00501" name="l00501"></a><span class="lineno"> 501</span> <a class="code hl_define" href="log_8h.html#a053d6037d543b84ce59308ce71d15cd1">FATAL</a>(<span class="stringliteral">"Could not seek to data start position"</span>);</div>
|
||
<div class="line"><a id="l00502" name="l00502"></a><span class="lineno"> 502</span> errno = <a class="code hl_define" href="errors_8h.html#a05c6aa0d46349e5060d75d5b6308d1e3">AARUF_ERROR_CANNOT_CREATE_FILE</a>;</div>
|
||
<div class="line"><a id="l00503" name="l00503"></a><span class="lineno"> 503</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Exiting aaruf_create() = NULL"</span>);</div>
|
||
<div class="line"><a id="l00504" name="l00504"></a><span class="lineno"> 504</span> <a class="code hl_function" href="create_8c.html#ae92275e097d4193d960bb97311b9cd78">cleanup_failed_create</a>(ctx);</div>
|
||
<div class="line"><a id="l00505" name="l00505"></a><span class="lineno"> 505</span> <span class="keywordflow">return</span> NULL;</div>
|
||
<div class="line"><a id="l00506" name="l00506"></a><span class="lineno"> 506</span> }</div>
|
||
<div class="line"><a id="l00507" name="l00507"></a><span class="lineno"> 507</span> </div>
|
||
<div class="line"><a id="l00508" name="l00508"></a><span class="lineno"> 508</span> <span class="comment">// Initialize index entries array</span></div>
|
||
<div class="line"><a id="l00509" name="l00509"></a><span class="lineno"> 509</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Initializing index entries array"</span>);</div>
|
||
<div class="line"><a id="l00510" name="l00510"></a><span class="lineno"> 510</span> <span class="keyword">const</span> UT_icd index_entry_icd = {<span class="keyword">sizeof</span>(<a class="code hl_struct" href="structIndexEntry.html">IndexEntry</a>), NULL, NULL, NULL};</div>
|
||
<div class="line"><a id="l00511" name="l00511"></a><span class="lineno"> 511</span> utarray_new(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab97a719a5b4186695b67143db7376152">index_entries</a>, &index_entry_icd);</div>
|
||
<div class="line"><a id="l00512" name="l00512"></a><span class="lineno"> 512</span> </div>
|
||
<div class="line"><a id="l00513" name="l00513"></a><span class="lineno"> 513</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab97a719a5b4186695b67143db7376152">index_entries</a> == NULL)</div>
|
||
<div class="line"><a id="l00514" name="l00514"></a><span class="lineno"> 514</span> {</div>
|
||
<div class="line"><a id="l00515" name="l00515"></a><span class="lineno"> 515</span> <a class="code hl_define" href="log_8h.html#a053d6037d543b84ce59308ce71d15cd1">FATAL</a>(<span class="stringliteral">"Not enough memory to create index entries array"</span>);</div>
|
||
<div class="line"><a id="l00516" name="l00516"></a><span class="lineno"> 516</span> errno = <a class="code hl_define" href="errors_8h.html#a35a771e3648bf971a004d4b2be9b5ec4">AARUF_ERROR_NOT_ENOUGH_MEMORY</a>;</div>
|
||
<div class="line"><a id="l00517" name="l00517"></a><span class="lineno"> 517</span> </div>
|
||
<div class="line"><a id="l00518" name="l00518"></a><span class="lineno"> 518</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Exiting aaruf_create() = NULL"</span>);</div>
|
||
<div class="line"><a id="l00519" name="l00519"></a><span class="lineno"> 519</span> <a class="code hl_function" href="create_8c.html#ae92275e097d4193d960bb97311b9cd78">cleanup_failed_create</a>(ctx);</div>
|
||
<div class="line"><a id="l00520" name="l00520"></a><span class="lineno"> 520</span> <span class="keywordflow">return</span> NULL;</div>
|
||
<div class="line"><a id="l00521" name="l00521"></a><span class="lineno"> 521</span> }</div>
|
||
<div class="line"><a id="l00522" name="l00522"></a><span class="lineno"> 522</span> </div>
|
||
<div class="line"><a id="l00523" name="l00523"></a><span class="lineno"> 523</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a130daf19dbed426f1c4c6f82691bc054">compression_enabled</a> = parsed_options.<a class="code hl_variable" href="structaaru__options.html#a4db2ac219f4d13ff2c35b8d62babaca2">compress</a>;</div>
|
||
<div class="line"><a id="l00524" name="l00524"></a><span class="lineno"> 524</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#adc67f6a6ef1602648bb064d47eb1fe88">lzma_dict_size</a> = parsed_options.<a class="code hl_variable" href="structaaru__options.html#a471cdd9988e95b36ee132cd047576237">dictionary</a>;</div>
|
||
<div class="line"><a id="l00525" name="l00525"></a><span class="lineno"> 525</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a0d4e1977913ce67e85bced41c58e5dd2">deduplicate</a> = parsed_options.<a class="code hl_variable" href="structaaru__options.html#a2d62d4cd6f1e59c145e3c4bc621f7d43">deduplicate</a>;</div>
|
||
<div class="line"><a id="l00526" name="l00526"></a><span class="lineno"> 526</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a0d4e1977913ce67e85bced41c58e5dd2">deduplicate</a>)</div>
|
||
<div class="line"><a id="l00527" name="l00527"></a><span class="lineno"> 527</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a18bee1dd72fd1ca4957ff6ddfebce343">sector_hash_map</a> = <a class="code hl_function" href="hash__map_8h.html#a4698f62d88ee9530fb93bf672455676f">create_map</a>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">user_data_ddt_header</a>.<a class="code hl_variable" href="structDdtHeader2.html#a9571c1d556e33537935bab1edba31135">blocks</a> * 25 / 100); <span class="comment">// 25% of total sectors</span></div>
|
||
<div class="line"><a id="l00528" name="l00528"></a><span class="lineno"> 528</span> </div>
|
||
<div class="line"><a id="l00529" name="l00529"></a><span class="lineno"> 529</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a551d4fb5a3213106d01d369e98bdf3c8">rewinded</a> = <span class="keyword">false</span>;</div>
|
||
<div class="line"><a id="l00530" name="l00530"></a><span class="lineno"> 530</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a1387f95c2da152594f29c5c276e5dbc5">last_written_block</a> = 0;</div>
|
||
<div class="line"><a id="l00531" name="l00531"></a><span class="lineno"> 531</span> </div>
|
||
<div class="line"><a id="l00532" name="l00532"></a><span class="lineno"> 532</span> <span class="keywordflow">if</span>(parsed_options.<a class="code hl_variable" href="structaaru__options.html#a93c09eed5b0613fa25dd84c7d3c2a416">md5</a>)</div>
|
||
<div class="line"><a id="l00533" name="l00533"></a><span class="lineno"> 533</span> {</div>
|
||
<div class="line"><a id="l00534" name="l00534"></a><span class="lineno"> 534</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a95770f959cae3b6b34e2b1ae592a7136">calculating_md5</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00535" name="l00535"></a><span class="lineno"> 535</span> <a class="code hl_function" href="decls_8h.html#a1e614476485ba9f46e3ac79858210f63">aaruf_md5_init</a>(&ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3c44b0cbcfb4586ce666dcd97a3dd85a">md5_context</a>);</div>
|
||
<div class="line"><a id="l00536" name="l00536"></a><span class="lineno"> 536</span> }</div>
|
||
<div class="line"><a id="l00537" name="l00537"></a><span class="lineno"> 537</span> <span class="keywordflow">if</span>(parsed_options.<a class="code hl_variable" href="structaaru__options.html#ae3ff963481af06c7e097bdaa0c925bb6">sha1</a>)</div>
|
||
<div class="line"><a id="l00538" name="l00538"></a><span class="lineno"> 538</span> {</div>
|
||
<div class="line"><a id="l00539" name="l00539"></a><span class="lineno"> 539</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a4e4c12388d90a11cf14266d1215ce13e">calculating_sha1</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00540" name="l00540"></a><span class="lineno"> 540</span> <a class="code hl_function" href="decls_8h.html#a9bcd5c47b9b593c95be9d4f82253739a">aaruf_sha1_init</a>(&ctx-><a class="code hl_variable" href="structaaruformat__context.html#ad1e28bac5a6c9bfdb8d18793686fc755">sha1_context</a>);</div>
|
||
<div class="line"><a id="l00541" name="l00541"></a><span class="lineno"> 541</span> }</div>
|
||
<div class="line"><a id="l00542" name="l00542"></a><span class="lineno"> 542</span> <span class="keywordflow">if</span>(parsed_options.<a class="code hl_variable" href="structaaru__options.html#a522d922c2ab6e04ce8e7051aaf953093">sha256</a>)</div>
|
||
<div class="line"><a id="l00543" name="l00543"></a><span class="lineno"> 543</span> {</div>
|
||
<div class="line"><a id="l00544" name="l00544"></a><span class="lineno"> 544</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a2e2c23ecc1d15087ef46e2591c47194a">calculating_sha256</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00545" name="l00545"></a><span class="lineno"> 545</span> <a class="code hl_function" href="decls_8h.html#a075527f7b15b70dc7028cf91d9062a90">aaruf_sha256_init</a>(&ctx-><a class="code hl_variable" href="structaaruformat__context.html#a21dffad51cfb58f5f71f7babee2aaceb">sha256_context</a>);</div>
|
||
<div class="line"><a id="l00546" name="l00546"></a><span class="lineno"> 546</span> }</div>
|
||
<div class="line"><a id="l00547" name="l00547"></a><span class="lineno"> 547</span> <span class="keywordflow">if</span>(parsed_options.<a class="code hl_variable" href="structaaru__options.html#a623a984dfec7abd375e7ef3d97333a4f">spamsum</a>)</div>
|
||
<div class="line"><a id="l00548" name="l00548"></a><span class="lineno"> 548</span> {</div>
|
||
<div class="line"><a id="l00549" name="l00549"></a><span class="lineno"> 549</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a865120510888fac8bb3597b57d515ba7">calculating_spamsum</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00550" name="l00550"></a><span class="lineno"> 550</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a729b87257c0b5d1e9abf1af133a4b0f3">spamsum_context</a> = <a class="code hl_function" href="decls_8h.html#a793dac760aedda6414ba4014eb2ed0c7">aaruf_spamsum_init</a>();</div>
|
||
<div class="line"><a id="l00551" name="l00551"></a><span class="lineno"> 551</span> }</div>
|
||
<div class="line"><a id="l00552" name="l00552"></a><span class="lineno"> 552</span> <span class="keywordflow">if</span>(parsed_options.<a class="code hl_variable" href="structaaru__options.html#abfbdc9267e6db5222e04ffd5a963b3a7">blake3</a>)</div>
|
||
<div class="line"><a id="l00553" name="l00553"></a><span class="lineno"> 553</span> {</div>
|
||
<div class="line"><a id="l00554" name="l00554"></a><span class="lineno"> 554</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a8b89a7e0e6369dad38e23dabaf4b49a4">blake3_context</a> = calloc(1, <span class="keyword">sizeof</span>(blake3_hasher));</div>
|
||
<div class="line"><a id="l00555" name="l00555"></a><span class="lineno"> 555</span> <span class="keywordflow">if</span>(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a8b89a7e0e6369dad38e23dabaf4b49a4">blake3_context</a> != NULL)</div>
|
||
<div class="line"><a id="l00556" name="l00556"></a><span class="lineno"> 556</span> {</div>
|
||
<div class="line"><a id="l00557" name="l00557"></a><span class="lineno"> 557</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a8be6dd9da00d771d24c7a6295f1c1d02">calculating_blake3</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00558" name="l00558"></a><span class="lineno"> 558</span> blake3_hasher_init(ctx-><a class="code hl_variable" href="structaaruformat__context.html#a8b89a7e0e6369dad38e23dabaf4b49a4">blake3_context</a>);</div>
|
||
<div class="line"><a id="l00559" name="l00559"></a><span class="lineno"> 559</span> }</div>
|
||
<div class="line"><a id="l00560" name="l00560"></a><span class="lineno"> 560</span> }</div>
|
||
<div class="line"><a id="l00561" name="l00561"></a><span class="lineno"> 561</span> </div>
|
||
<div class="line"><a id="l00562" name="l00562"></a><span class="lineno"> 562</span> <span class="comment">// Is writing</span></div>
|
||
<div class="line"><a id="l00563" name="l00563"></a><span class="lineno"> 563</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a6f61f9ea20f4e3b791a0d6388dd43651">is_writing</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00564" name="l00564"></a><span class="lineno"> 564</span> </div>
|
||
<div class="line"><a id="l00565" name="l00565"></a><span class="lineno"> 565</span> <span class="comment">// Initialize dirty flags - all true by default for new images</span></div>
|
||
<div class="line"><a id="l00566" name="l00566"></a><span class="lineno"> 566</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ad1e4ceb44652cacfc63e0e2c95f570c6">dirty_secondary_ddt</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00567" name="l00567"></a><span class="lineno"> 567</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a2f095c3433eb29d2bf421b1e3355e72d">dirty_primary_ddt</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00568" name="l00568"></a><span class="lineno"> 568</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a7ae2128b4ae5511c2c601ec8e8f66387">dirty_single_level_ddt</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00569" name="l00569"></a><span class="lineno"> 569</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a0d06526ba707ed15763457e53a00673d">dirty_checksum_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00570" name="l00570"></a><span class="lineno"> 570</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a4f10051f78c63709ccc01cca3ba5a22f">dirty_tracks_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00571" name="l00571"></a><span class="lineno"> 571</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a47b4ad72f562022ffac686c59b33057f">dirty_mode2_subheaders_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00572" name="l00572"></a><span class="lineno"> 572</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a60a07b295752e19284649743c43122c2">dirty_sector_prefix_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00573" name="l00573"></a><span class="lineno"> 573</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab977bf7c003408fa90116d1b441780ea">dirty_sector_prefix_ddt</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00574" name="l00574"></a><span class="lineno"> 574</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a3c6d8057776a41c478df60ee228b2cf4">dirty_sector_suffix_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00575" name="l00575"></a><span class="lineno"> 575</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a9755effb4c78f872b840c62566fa6e4a">dirty_sector_suffix_ddt</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00576" name="l00576"></a><span class="lineno"> 576</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab268908ef1517931e68c19f9ddd63269">dirty_sector_subchannel_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00577" name="l00577"></a><span class="lineno"> 577</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ab5aef7d04dd9d157b63e0aad49408e8b">dirty_dvd_long_sector_blocks</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00578" name="l00578"></a><span class="lineno"> 578</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a43de9f79e2d7063d5f120c63301800e3">dirty_dvd_title_key_decrypted_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00579" name="l00579"></a><span class="lineno"> 579</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a182f0f2c49aeb3b2f4ed8e7625d1cf46">dirty_media_tags</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00580" name="l00580"></a><span class="lineno"> 580</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#ad5e046ffc70066ba070dc58514b3a771">dirty_tape_ddt</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00581" name="l00581"></a><span class="lineno"> 581</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#abdf9ca4ea03bb2080831fc9aaa127422">dirty_tape_file_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00582" name="l00582"></a><span class="lineno"> 582</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a482f84e538a27a4b8686ad27c449bee9">dirty_tape_partition_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00583" name="l00583"></a><span class="lineno"> 583</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#aeb85241fdc8a4ac27aee8acab5ceec17">dirty_geometry_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00584" name="l00584"></a><span class="lineno"> 584</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#aab573afda1087dcc99dc9a6a34fcc844">dirty_metadata_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00585" name="l00585"></a><span class="lineno"> 585</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#aa9fb206d36b68370f2435899c79abbfd">dirty_dumphw_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00586" name="l00586"></a><span class="lineno"> 586</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a4bdcfa521eb92c949081adca481f01fd">dirty_cicm_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00587" name="l00587"></a><span class="lineno"> 587</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a6f3db4b3d6f4351edae1353b0815795e">dirty_json_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00588" name="l00588"></a><span class="lineno"> 588</span> ctx-><a class="code hl_variable" href="structaaruformat__context.html#a63616c8450e9e1853e0645714fe310cb">dirty_index_block</a> = <span class="keyword">true</span>;</div>
|
||
<div class="line"><a id="l00589" name="l00589"></a><span class="lineno"> 589</span> </div>
|
||
<div class="line"><a id="l00590" name="l00590"></a><span class="lineno"> 590</span> <a class="code hl_define" href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a>(<span class="stringliteral">"Exiting aaruf_create() = %p"</span>, ctx);</div>
|
||
<div class="line"><a id="l00591" name="l00591"></a><span class="lineno"> 591</span> <span class="comment">// Return context</span></div>
|
||
<div class="line"><a id="l00592" name="l00592"></a><span class="lineno"> 592</span> <span class="keywordflow">return</span> ctx;</div>
|
||
<div class="line"><a id="l00593" name="l00593"></a><span class="lineno"> 593</span>}</div>
|
||
</div>
|
||
<div class="ttc" id="aaaruformat_8h_html"><div class="ttname"><a href="aaruformat_8h.html">aaruformat.h</a></div></div>
|
||
<div class="ttc" id="aaaruformat_8h_html_a1341a1043d24b7d7e234fcbfe52dd907"><div class="ttname"><a href="aaruformat_8h.html#a1341a1043d24b7d7e234fcbfe52dd907">LIBAARUFORMAT_MAJOR_VERSION</a></div><div class="ttdeci">#define LIBAARUFORMAT_MAJOR_VERSION</div><div class="ttdef"><b>Definition</b> <a href="aaruformat_8h_source.html#l00022">aaruformat.h:22</a></div></div>
|
||
<div class="ttc" id="aaaruformat_8h_html_a9258501500f40e275641fca951a3ce04"><div class="ttname"><a href="aaruformat_8h.html#a9258501500f40e275641fca951a3ce04">LIBAARUFORMAT_MINOR_VERSION</a></div><div class="ttdeci">#define LIBAARUFORMAT_MINOR_VERSION</div><div class="ttdef"><b>Definition</b> <a href="aaruformat_8h_source.html#l00023">aaruformat.h:23</a></div></div>
|
||
<div class="ttc" id="aconsts_8h_html_a3c3ba66fe2b547655c9e4b16a1ba519a"><div class="ttname"><a href="consts_8h.html#a3c3ba66fe2b547655c9e4b16a1ba519a">AARU_MAGIC</a></div><div class="ttdeci">#define AARU_MAGIC</div><div class="ttdoc">Magic identifier for AaruFormat container (ASCII "AARUFRMT").</div><div class="ttdef"><b>Definition</b> <a href="consts_8h_source.html#l00064">consts.h:64</a></div></div>
|
||
<div class="ttc" id="aconsts_8h_html_a6c8469dfe973ac952cf40394bd2c160b"><div class="ttname"><a href="consts_8h.html#a6c8469dfe973ac952cf40394bd2c160b">MAX_CACHE_SIZE</a></div><div class="ttdeci">#define MAX_CACHE_SIZE</div><div class="ttdoc">Maximum read cache size (bytes).</div><div class="ttdef"><b>Definition</b> <a href="consts_8h_source.html#l00079">consts.h:79</a></div></div>
|
||
<div class="ttc" id="aconsts_8h_html_ad2fdced5805aa0364f1c5b073f81dd76"><div class="ttname"><a href="consts_8h.html#ad2fdced5805aa0364f1c5b073f81dd76">AARUF_VERSION_V2</a></div><div class="ttdeci">#define AARUF_VERSION_V2</div><div class="ttdoc">Second on‑disk version (C implementation).</div><div class="ttdef"><b>Definition</b> <a href="consts_8h_source.html#l00075">consts.h:75</a></div></div>
|
||
<div class="ttc" id="acreate_8c_html_a8fc1d6adf1ec5cc7d7bb9c067aff9f6e"><div class="ttname"><a href="create_8c.html#a8fc1d6adf1ec5cc7d7bb9c067aff9f6e">aaruf_create</a></div><div class="ttdeci">void * aaruf_create(const char *filepath, const uint32_t media_type, const uint32_t sector_size, const uint64_t user_sectors, const uint64_t negative_sectors, const uint64_t overflow_sectors, const char *options, const uint8_t *application_name, const uint8_t application_name_length, const uint8_t application_major_version, const uint8_t application_minor_version, const bool is_tape)</div><div class="ttdoc">Creates a new AaruFormat image file.</div><div class="ttdef"><b>Definition</b> <a href="#l00279">create.c:279</a></div></div>
|
||
<div class="ttc" id="acreate_8c_html_ae92275e097d4193d960bb97311b9cd78"><div class="ttname"><a href="create_8c.html#ae92275e097d4193d960bb97311b9cd78">cleanup_failed_create</a></div><div class="ttdeci">static void cleanup_failed_create(aaruformat_context *ctx)</div><div class="ttdef"><b>Definition</b> <a href="#l00030">create.c:30</a></div></div>
|
||
<div class="ttc" id="adecls_8h_html_a018e0da1c1f7e4f6187a982c0e40e056"><div class="ttname"><a href="decls_8h.html#a018e0da1c1f7e4f6187a982c0e40e056">AARU_CALL</a></div><div class="ttdeci">#define AARU_CALL</div><div class="ttdef"><b>Definition</b> <a href="decls_8h_source.html#l00045">decls.h:45</a></div></div>
|
||
<div class="ttc" id="adecls_8h_html_a075527f7b15b70dc7028cf91d9062a90"><div class="ttname"><a href="decls_8h.html#a075527f7b15b70dc7028cf91d9062a90">aaruf_sha256_init</a></div><div class="ttdeci">void aaruf_sha256_init(sha256_ctx *ctx)</div><div class="ttdef"><b>Definition</b> <a href="sha256_8c_source.html#l00076">sha256.c:76</a></div></div>
|
||
<div class="ttc" id="adecls_8h_html_a1e614476485ba9f46e3ac79858210f63"><div class="ttname"><a href="decls_8h.html#a1e614476485ba9f46e3ac79858210f63">aaruf_md5_init</a></div><div class="ttdeci">void aaruf_md5_init(md5_ctx *ctx)</div><div class="ttdef"><b>Definition</b> <a href="md5_8c_source.html#l00436">md5.c:436</a></div></div>
|
||
<div class="ttc" id="adecls_8h_html_a6fe74704e44be7adfaa2ce676f3c3de4"><div class="ttname"><a href="decls_8h.html#a6fe74704e44be7adfaa2ce676f3c3de4">aaruf_spamsum_free</a></div><div class="ttdeci">void aaruf_spamsum_free(spamsum_ctx *ctx)</div><div class="ttdoc">Frees a spamsum (fuzzy hash) context.</div><div class="ttdef"><b>Definition</b> <a href="spamsum_8c_source.html#l00075">spamsum.c:75</a></div></div>
|
||
<div class="ttc" id="adecls_8h_html_a793dac760aedda6414ba4014eb2ed0c7"><div class="ttname"><a href="decls_8h.html#a793dac760aedda6414ba4014eb2ed0c7">aaruf_spamsum_init</a></div><div class="ttdeci">spamsum_ctx * aaruf_spamsum_init(void)</div><div class="ttdef"><b>Definition</b> <a href="spamsum_8c_source.html#l00037">spamsum.c:37</a></div></div>
|
||
<div class="ttc" id="adecls_8h_html_a9001412c35f3c92d3a9320d27b0d97f9"><div class="ttname"><a href="decls_8h.html#a9001412c35f3c92d3a9320d27b0d97f9">AARU_EXPORT</a></div><div class="ttdeci">#define AARU_EXPORT</div><div class="ttdef"><b>Definition</b> <a href="decls_8h_source.html#l00054">decls.h:54</a></div></div>
|
||
<div class="ttc" id="adecls_8h_html_a9bcd5c47b9b593c95be9d4f82253739a"><div class="ttname"><a href="decls_8h.html#a9bcd5c47b9b593c95be9d4f82253739a">aaruf_sha1_init</a></div><div class="ttdeci">void aaruf_sha1_init(sha1_ctx *ctx)</div><div class="ttdef"><b>Definition</b> <a href="sha1_8c_source.html#l00034">sha1.c:34</a></div></div>
|
||
<div class="ttc" id="adecls_8h_html_ac1a30bb251ac148f485c51593c0740c1"><div class="ttname"><a href="decls_8h.html#ac1a30bb251ac148f485c51593c0740c1">aaruf_ecc_cd_init</a></div><div class="ttdeci">void * aaruf_ecc_cd_init()</div><div class="ttdoc">Initializes a Compact Disc ECC context.</div><div class="ttdef"><b>Definition</b> <a href="ecc__cd_8c_source.html#l00035">ecc_cd.c:35</a></div></div>
|
||
<div class="ttc" id="adecls_8h_html_ac5f5334a51424028574a5433a0e24b20"><div class="ttname"><a href="decls_8h.html#ac5f5334a51424028574a5433a0e24b20">aaruf_get_xml_mediatype</a></div><div class="ttdeci">int32_t aaruf_get_xml_mediatype(int32_t type)</div><div class="ttdef"><b>Definition</b> <a href="helpers_8c_source.html#l00347">helpers.c:347</a></div></div>
|
||
<div class="ttc" id="aenums_8h_html"><div class="ttname"><a href="enums_8h.html">enums.h</a></div></div>
|
||
<div class="ttc" id="aenums_8h_html_a54420623f26ab6bb61042b41cccf37a3aba4d0f50b26af1d0292daaa0d70feacf"><div class="ttname"><a href="enums_8h.html#a54420623f26ab6bb61042b41cccf37a3aba4d0f50b26af1d0292daaa0d70feacf">DeDuplicationTable2</a></div><div class="ttdeci">@ DeDuplicationTable2</div><div class="ttdoc">Block containing a deduplication table v2.</div><div class="ttdef"><b>Definition</b> <a href="enums_8h_source.html#l00143">enums.h:143</a></div></div>
|
||
<div class="ttc" id="aenums_8h_html_ad8ed01ff3ff33333d8e19db4d2818bb6a73bb26133ccd01972725933b00ec3a06"><div class="ttname"><a href="enums_8h.html#ad8ed01ff3ff33333d8e19db4d2818bb6a73bb26133ccd01972725933b00ec3a06">UserData</a></div><div class="ttdeci">@ UserData</div><div class="ttdoc">User (main) data.</div><div class="ttdef"><b>Definition</b> <a href="enums_8h_source.html#l00046">enums.h:46</a></div></div>
|
||
<div class="ttc" id="aenums_8h_html_affec749ed88365143745313ae9168263ac9d3e887722f2bc482bcca9d41c512af"><div class="ttname"><a href="enums_8h.html#affec749ed88365143745313ae9168263ac9d3e887722f2bc482bcca9d41c512af">None</a></div><div class="ttdeci">@ None</div><div class="ttdoc">Not compressed.</div><div class="ttdef"><b>Definition</b> <a href="enums_8h_source.html#l00033">enums.h:33</a></div></div>
|
||
<div class="ttc" id="aerrors_8h_html_a05c6aa0d46349e5060d75d5b6308d1e3"><div class="ttname"><a href="errors_8h.html#a05c6aa0d46349e5060d75d5b6308d1e3">AARUF_ERROR_CANNOT_CREATE_FILE</a></div><div class="ttdeci">#define AARUF_ERROR_CANNOT_CREATE_FILE</div><div class="ttdoc">Output file could not be created / opened for write.</div><div class="ttdef"><b>Definition</b> <a href="errors_8h_source.html#l00058">errors.h:58</a></div></div>
|
||
<div class="ttc" id="aerrors_8h_html_a24494b154606028b04c1d71367545e5c"><div class="ttname"><a href="errors_8h.html#a24494b154606028b04c1d71367545e5c">AARUF_ERROR_INVALID_APP_NAME_LENGTH</a></div><div class="ttdeci">#define AARUF_ERROR_INVALID_APP_NAME_LENGTH</div><div class="ttdoc">Application name field length invalid (sanity limit).</div><div class="ttdef"><b>Definition</b> <a href="errors_8h_source.html#l00059">errors.h:59</a></div></div>
|
||
<div class="ttc" id="aerrors_8h_html_a35a771e3648bf971a004d4b2be9b5ec4"><div class="ttname"><a href="errors_8h.html#a35a771e3648bf971a004d4b2be9b5ec4">AARUF_ERROR_NOT_ENOUGH_MEMORY</a></div><div class="ttdeci">#define AARUF_ERROR_NOT_ENOUGH_MEMORY</div><div class="ttdoc">Memory allocation failure (critical).</div><div class="ttdef"><b>Definition</b> <a href="errors_8h_source.html#l00048">errors.h:48</a></div></div>
|
||
<div class="ttc" id="agroup__SectorTags_html_ggaf863e81d172ce7a216d8687a8a23293aa81dbcd4677b6377bce5351ad92fc4d64"><div class="ttname"><a href="group__SectorTags.html#ggaf863e81d172ce7a216d8687a8a23293aa81dbcd4677b6377bce5351ad92fc4d64">MaxSectorTag</a></div><div class="ttdeci">@ MaxSectorTag</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00970">aaru.h:970</a></div></div>
|
||
<div class="ttc" id="ahash__map_8h_html_a4698f62d88ee9530fb93bf672455676f"><div class="ttname"><a href="hash__map_8h.html#a4698f62d88ee9530fb93bf672455676f">create_map</a></div><div class="ttdeci">hash_map_t * create_map(size_t size)</div><div class="ttdoc">Creates a new hash map with the specified initial size.</div><div class="ttdef"><b>Definition</b> <a href="hash__map_8c_source.html#l00049">hash_map.c:49</a></div></div>
|
||
<div class="ttc" id="ahash__map_8h_html_ab885e8c5bedaf6f3cca1877e378fd04f"><div class="ttname"><a href="hash__map_8h.html#ab885e8c5bedaf6f3cca1877e378fd04f">free_map</a></div><div class="ttdeci">void free_map(hash_map_t *map)</div><div class="ttdoc">Frees all memory associated with a hash map.</div><div class="ttdef"><b>Definition</b> <a href="hash__map_8c_source.html#l00073">hash_map.c:73</a></div></div>
|
||
<div class="ttc" id="aheader_8h_html_a57c99b24137b82f12950e79ffbd2fb7a"><div class="ttname"><a href="header_8h.html#a57c99b24137b82f12950e79ffbd2fb7a">GUID_SIZE</a></div><div class="ttdeci">#define GUID_SIZE</div><div class="ttdoc">Size in bytes of GUID / UUID-like binary identifier.</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00060">header.h:60</a></div></div>
|
||
<div class="ttc" id="aheader_8h_html_ab17964dacc36dca03ec5e75aa40a4502"><div class="ttname"><a href="header_8h.html#ab17964dacc36dca03ec5e75aa40a4502">AARU_HEADER_APP_NAME_LEN</a></div><div class="ttdeci">#define AARU_HEADER_APP_NAME_LEN</div><div class="ttdoc">Size in bytes (UTF-16LE) of application name field (32 UTF-16 code units).</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00059">header.h:59</a></div></div>
|
||
<div class="ttc" id="ainternal_8h_html"><div class="ttname"><a href="internal_8h.html">internal.h</a></div></div>
|
||
<div class="ttc" id="ainternal_8h_html_a36c1cca0e4cea9c2e0dffb582b836f6f"><div class="ttname"><a href="internal_8h.html#a36c1cca0e4cea9c2e0dffb582b836f6f">get_filetime_uint64</a></div><div class="ttdeci">uint64_t get_filetime_uint64()</div><div class="ttdoc">Gets the current time as a 64-bit FILETIME value.</div><div class="ttdef"><b>Definition</b> <a href="time_8c_source.html#l00045">time.c:45</a></div></div>
|
||
<div class="ttc" id="ainternal_8h_html_a7db9f44b931877b306de9cf7cd1deed2"><div class="ttname"><a href="internal_8h.html#a7db9f44b931877b306de9cf7cd1deed2">generate_random_bytes</a></div><div class="ttdeci">void generate_random_bytes(uint8_t *buffer, size_t length)</div><div class="ttdoc">Generates cryptographically strong random bytes.</div><div class="ttdef"><b>Definition</b> <a href="helpers_8c_source.html#l00480">helpers.c:480</a></div></div>
|
||
<div class="ttc" id="ainternal_8h_html_aaae42bff244df727b6c029f58d4957df"><div class="ttname"><a href="internal_8h.html#aaae42bff244df727b6c029f58d4957df">parse_options</a></div><div class="ttdeci">aaru_options parse_options(const char *options)</div><div class="ttdoc">Parses the options string for AaruFormat image creation/opening.</div><div class="ttdef"><b>Definition</b> <a href="options_8c_source.html#l00038">options.c:38</a></div></div>
|
||
<div class="ttc" id="alog_8h_html"><div class="ttname"><a href="log_8h.html">log.h</a></div></div>
|
||
<div class="ttc" id="alog_8h_html_a053d6037d543b84ce59308ce71d15cd1"><div class="ttname"><a href="log_8h.html#a053d6037d543b84ce59308ce71d15cd1">FATAL</a></div><div class="ttdeci">#define FATAL(fmt,...)</div><div class="ttdef"><b>Definition</b> <a href="log_8h_source.html#l00040">log.h:40</a></div></div>
|
||
<div class="ttc" id="alog_8h_html_a21cc0459b78d5f2d7bd737e5aae1278a"><div class="ttname"><a href="log_8h.html#a21cc0459b78d5f2d7bd737e5aae1278a">TRACE</a></div><div class="ttdeci">#define TRACE(fmt,...)</div><div class="ttdef"><b>Definition</b> <a href="log_8h_source.html#l00025">log.h:25</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html"><div class="ttname"><a href="structAaruHeaderV2.html">AaruHeaderV2</a></div><div class="ttdoc">Version 2 container header with GUID, alignment shifts, and feature negotiation bitmaps.</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00106">header.h:107</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_a0afcf9a5f565a9053351f44234c90dc3"><div class="ttname"><a href="structAaruHeaderV2.html#a0afcf9a5f565a9053351f44234c90dc3">AaruHeaderV2::application</a></div><div class="ttdeci">uint8_t application[64]</div><div class="ttdoc">UTF-8 creator application name (fixed 64 bytes).</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00109">header.h:109</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_a1c26feafd945328f8f1854b523a0f03c"><div class="ttname"><a href="structAaruHeaderV2.html#a1c26feafd945328f8f1854b523a0f03c">AaruHeaderV2::applicationMajorVersion</a></div><div class="ttdeci">uint8_t applicationMajorVersion</div><div class="ttdoc">Creator application major version.</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00112">header.h:112</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_a27af1bfabbc7650471a6010475116697"><div class="ttname"><a href="structAaruHeaderV2.html#a27af1bfabbc7650471a6010475116697">AaruHeaderV2::identifier</a></div><div class="ttdeci">uint64_t identifier</div><div class="ttdoc">File magic (AARU_MAGIC).</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00108">header.h:108</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_a45bc7e2afc9008ce6f4ae1dba93bdac3"><div class="ttname"><a href="structAaruHeaderV2.html#a45bc7e2afc9008ce6f4ae1dba93bdac3">AaruHeaderV2::lastWrittenTime</a></div><div class="ttdeci">int64_t lastWrittenTime</div><div class="ttdoc">Last modification FILETIME (100 ns since 1601-01-01 UTC).</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00117">header.h:117</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_a4ec4b1d593f5a0af19f6d7b8eaeada40"><div class="ttname"><a href="structAaruHeaderV2.html#a4ec4b1d593f5a0af19f6d7b8eaeada40">AaruHeaderV2::indexOffset</a></div><div class="ttdeci">uint64_t indexOffset</div><div class="ttdoc">Absolute byte offset to primary index block (MUST be > 0; 0 => corrupt/unreadable).</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00115">header.h:115</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_a5ae79accbb8ba2762d01a63ad334ee60"><div class="ttname"><a href="structAaruHeaderV2.html#a5ae79accbb8ba2762d01a63ad334ee60">AaruHeaderV2::applicationMinorVersion</a></div><div class="ttdeci">uint8_t applicationMinorVersion</div><div class="ttdoc">Creator application minor / patch version.</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00113">header.h:113</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_a69ff1a1dbdaf0501e6488451b7270b51"><div class="ttname"><a href="structAaruHeaderV2.html#a69ff1a1dbdaf0501e6488451b7270b51">AaruHeaderV2::guid</a></div><div class="ttdeci">uint8_t guid[16]</div><div class="ttdoc">128-bit image GUID (binary, not text); stable across children.</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00118">header.h:118</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_a81b114ab2b1fa786f64e9e914af3ba27"><div class="ttname"><a href="structAaruHeaderV2.html#a81b114ab2b1fa786f64e9e914af3ba27">AaruHeaderV2::mediaType</a></div><div class="ttdeci">uint32_t mediaType</div><div class="ttdoc">Media type enumeration (value from MediaType).</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00114">header.h:114</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_ae2d6d3c7bc0a1956fb246cf7acbddeeb"><div class="ttname"><a href="structAaruHeaderV2.html#ae2d6d3c7bc0a1956fb246cf7acbddeeb">AaruHeaderV2::imageMinorVersion</a></div><div class="ttdeci">uint8_t imageMinorVersion</div><div class="ttdoc">Container format minor version.</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00111">header.h:111</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_ae849dae5af5cf31b1b815ef67b3c621f"><div class="ttname"><a href="structAaruHeaderV2.html#ae849dae5af5cf31b1b815ef67b3c621f">AaruHeaderV2::creationTime</a></div><div class="ttdeci">int64_t creationTime</div><div class="ttdoc">Creation FILETIME (100 ns since 1601-01-01 UTC).</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00116">header.h:116</a></div></div>
|
||
<div class="ttc" id="astructAaruHeaderV2_html_af79ca31bcd428d1a54ac25c30d09b7a7"><div class="ttname"><a href="structAaruHeaderV2.html#af79ca31bcd428d1a54ac25c30d09b7a7">AaruHeaderV2::imageMajorVersion</a></div><div class="ttdeci">uint8_t imageMajorVersion</div><div class="ttdoc">Container format major version.</div><div class="ttdef"><b>Definition</b> <a href="header_8h_source.html#l00110">header.h:110</a></div></div>
|
||
<div class="ttc" id="astructCacheHeader_html_a44229bb929d8949f3c2700d07123d224"><div class="ttname"><a href="structCacheHeader.html#a44229bb929d8949f3c2700d07123d224">CacheHeader::cache</a></div><div class="ttdeci">struct CacheEntry * cache</div><div class="ttdoc">Hash root (uthash). NULL when empty.</div><div class="ttdef"><b>Definition</b> <a href="lru_8h_source.html#l00048">lru.h:48</a></div></div>
|
||
<div class="ttc" id="astructCacheHeader_html_ad3b962f8ce6c6115143cf581c7936e55"><div class="ttname"><a href="structCacheHeader.html#ad3b962f8ce6c6115143cf581c7936e55">CacheHeader::max_items</a></div><div class="ttdeci">uint64_t max_items</div><div class="ttdoc">Hard limit for number of entries (policy: enforce/ignore depends on implementation).</div><div class="ttdef"><b>Definition</b> <a href="lru_8h_source.html#l00047">lru.h:47</a></div></div>
|
||
<div class="ttc" id="astructCdEccContext_html"><div class="ttname"><a href="structCdEccContext.html">CdEccContext</a></div><div class="ttdoc">Lookup tables and state for Compact Disc EDC/ECC (P/Q) regeneration / verification.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00085">context.h:86</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html"><div class="ttname"><a href="structDdtHeader2.html">DdtHeader2</a></div><div class="ttdoc">Header preceding a version 2 hierarchical deduplication table.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00141">ddt.h:142</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_a14f9ccf36df63e036d69291182cf7bbb"><div class="ttname"><a href="structDdtHeader2.html#a14f9ccf36df63e036d69291182cf7bbb">DdtHeader2::type</a></div><div class="ttdeci">uint16_t type</div><div class="ttdoc">Data classification (DataType) for sectors referenced by this table.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00144">ddt.h:144</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_a238a2ca31ce0f60af3e59a1cb3e2e73c"><div class="ttname"><a href="structDdtHeader2.html#a238a2ca31ce0f60af3e59a1cb3e2e73c">DdtHeader2::start</a></div><div class="ttdeci">uint64_t start</div><div class="ttdoc">Base internal index covered by this table (used for secondary tables; currently informational).</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00153">ddt.h:153</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_a2bfa558d9d778ae6b86d52520e278b66"><div class="ttname"><a href="structDdtHeader2.html#a2bfa558d9d778ae6b86d52520e278b66">DdtHeader2::overflow</a></div><div class="ttdeci">uint16_t overflow</div><div class="ttdoc">Trailing dumped sectors beyond user area (overflow range), still mapped with entries.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00151">ddt.h:151</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_a4e90c22109c3fff37b526a113b094a50"><div class="ttname"><a href="structDdtHeader2.html#a4e90c22109c3fff37b526a113b094a50">DdtHeader2::entries</a></div><div class="ttdeci">uint64_t entries</div><div class="ttdoc">Number of entries contained in (uncompressed) table payload.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00158">ddt.h:158</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_a68f4825db4e22906af0e55a359360656"><div class="ttname"><a href="structDdtHeader2.html#a68f4825db4e22906af0e55a359360656">DdtHeader2::levels</a></div><div class="ttdeci">uint8_t levels</div><div class="ttdoc">Total number of hierarchy levels (root depth); > 0.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00146">ddt.h:146</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_a80a88ec68cd0332a57886ac363bfa4d1"><div class="ttname"><a href="structDdtHeader2.html#a80a88ec68cd0332a57886ac363bfa4d1">DdtHeader2::identifier</a></div><div class="ttdeci">uint32_t identifier</div><div class="ttdoc">Block identifier, must be BlockType::DeDuplicationTable2.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00143">ddt.h:143</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_a8c2110cbb42bde3c0e302d3429024b04"><div class="ttname"><a href="structDdtHeader2.html#a8c2110cbb42bde3c0e302d3429024b04">DdtHeader2::tableShift</a></div><div class="ttdeci">uint8_t tableShift</div><div class="ttdoc">2^tableShift = number of logical sectors per primary entry (multi-level only; 0 for single-level or s...</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00156">ddt.h:156</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_a9571c1d556e33537935bab1edba31135"><div class="ttname"><a href="structDdtHeader2.html#a9571c1d556e33537935bab1edba31135">DdtHeader2::blocks</a></div><div class="ttdeci">uint64_t blocks</div><div class="ttdoc">Total internal span (negative + usable + overflow) in logical sectors.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00150">ddt.h:150</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_aa4b1416ac0e0585f436513cacf9ebd74"><div class="ttname"><a href="structDdtHeader2.html#aa4b1416ac0e0585f436513cacf9ebd74">DdtHeader2::negative</a></div><div class="ttdeci">uint16_t negative</div><div class="ttdoc">Leading negative LBA count; added to external L to build internal index.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00149">ddt.h:149</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_aa67b097c3a20f926ede495d27152f1c0"><div class="ttname"><a href="structDdtHeader2.html#aa67b097c3a20f926ede495d27152f1c0">DdtHeader2::blockAlignmentShift</a></div><div class="ttdeci">uint8_t blockAlignmentShift</div><div class="ttdoc">2^blockAlignmentShift = block alignment boundary in bytes.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00154">ddt.h:154</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_ac8ec7921a5651b5107eda4e99b488798"><div class="ttname"><a href="structDdtHeader2.html#ac8ec7921a5651b5107eda4e99b488798">DdtHeader2::tableLevel</a></div><div class="ttdeci">uint8_t tableLevel</div><div class="ttdoc">Zero-based level index of this table (0 = root, increases downward).</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00147">ddt.h:147</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_ad1a27a46df09748a91a9010a630c422e"><div class="ttname"><a href="structDdtHeader2.html#ad1a27a46df09748a91a9010a630c422e">DdtHeader2::compression</a></div><div class="ttdeci">uint16_t compression</div><div class="ttdoc">Compression algorithm for this table body (CompressionType).</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00145">ddt.h:145</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_ad9a2beb3a79bc6c239ba04fe341e0cde"><div class="ttname"><a href="structDdtHeader2.html#ad9a2beb3a79bc6c239ba04fe341e0cde">DdtHeader2::dataShift</a></div><div class="ttdeci">uint8_t dataShift</div><div class="ttdoc">2^dataShift = sectors represented per increment in blockIndex field.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00155">ddt.h:155</a></div></div>
|
||
<div class="ttc" id="astructDdtHeader2_html_af71423c2a8c7fa89dfd2313b456c57a2"><div class="ttname"><a href="structDdtHeader2.html#af71423c2a8c7fa89dfd2313b456c57a2">DdtHeader2::previousLevelOffset</a></div><div class="ttdeci">uint64_t previousLevelOffset</div><div class="ttdoc">Absolute byte offset of the parent (previous) level table; 0 if root.</div><div class="ttdef"><b>Definition</b> <a href="ddt_8h_source.html#l00148">ddt.h:148</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_a76611d5087e0a9fd4d329fac7c9ec3f3"><div class="ttname"><a href="structImageInfo.html#a76611d5087e0a9fd4d329fac7c9ec3f3">ImageInfo::MediaType</a></div><div class="ttdeci">uint32_t MediaType</div><div class="ttdoc">Media type identifier (see MediaType enum; 0=Unknown)</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00933">aaru.h:933</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_a7ed25efcf8cec55d6609b83bcd17b2d0"><div class="ttname"><a href="structImageInfo.html#a7ed25efcf8cec55d6609b83bcd17b2d0">ImageInfo::MetadataMediaType</a></div><div class="ttdeci">uint8_t MetadataMediaType</div><div class="ttdoc">Media type for sidecar generation (internal archival use)</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00934">aaru.h:934</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_aac1ac48f57afd415467cd6f13f01644b"><div class="ttname"><a href="structImageInfo.html#aac1ac48f57afd415467cd6f13f01644b">ImageInfo::SectorSize</a></div><div class="ttdeci">uint32_t SectorSize</div><div class="ttdoc">Size of each logical sector in bytes (512, 2048, 2352, 4096, etc.)</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00927">aaru.h:927</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_aaea8b3a14fc03f9a4b045318160b7f54"><div class="ttname"><a href="structImageInfo.html#aaea8b3a14fc03f9a4b045318160b7f54">ImageInfo::Application</a></div><div class="ttdeci">char Application[64]</div><div class="ttdoc">Name of application that created the image (NUL-terminated)</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00929">aaru.h:929</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_abca8e73a9655d810e6d30d36c3ab54d7"><div class="ttname"><a href="structImageInfo.html#abca8e73a9655d810e6d30d36c3ab54d7">ImageInfo::ImageSize</a></div><div class="ttdeci">uint64_t ImageSize</div><div class="ttdoc">Size of the image payload in bytes (excludes headers/metadata)</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00925">aaru.h:925</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_acbccd97dbc139ed2f81d9997560725bb"><div class="ttname"><a href="structImageInfo.html#acbccd97dbc139ed2f81d9997560725bb">ImageInfo::CreationTime</a></div><div class="ttdeci">int64_t CreationTime</div><div class="ttdoc">Image creation timestamp (Windows FILETIME: 100ns since 1601-01-01 UTC)</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00931">aaru.h:931</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_ada8567fee9fbe636cb10f788b3705e3a"><div class="ttname"><a href="structImageInfo.html#ada8567fee9fbe636cb10f788b3705e3a">ImageInfo::LastModificationTime</a></div><div class="ttdeci">int64_t LastModificationTime</div><div class="ttdoc">Last modification timestamp (Windows FILETIME format)</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00932">aaru.h:932</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_adce978941d9900c8c05e620df67f8c5c"><div class="ttname"><a href="structImageInfo.html#adce978941d9900c8c05e620df67f8c5c">ImageInfo::Version</a></div><div class="ttdeci">char Version[32]</div><div class="ttdoc">Image format version string (NUL-terminated, e.g., "6.0")</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00928">aaru.h:928</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_ae3e1b9cde1c51152b00eb1b59e199906"><div class="ttname"><a href="structImageInfo.html#ae3e1b9cde1c51152b00eb1b59e199906">ImageInfo::Sectors</a></div><div class="ttdeci">uint64_t Sectors</div><div class="ttdoc">Total count of addressable logical sectors/blocks.</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00926">aaru.h:926</a></div></div>
|
||
<div class="ttc" id="astructImageInfo_html_aebf7783c46e640a8e7d0192ba2843e9a"><div class="ttname"><a href="structImageInfo.html#aebf7783c46e640a8e7d0192ba2843e9a">ImageInfo::ApplicationVersion</a></div><div class="ttdeci">char ApplicationVersion[32]</div><div class="ttdoc">Version of the creating application (NUL-terminated)</div><div class="ttdef"><b>Definition</b> <a href="aaru_8h_source.html#l00930">aaru.h:930</a></div></div>
|
||
<div class="ttc" id="astructIndexEntry_html"><div class="ttname"><a href="structIndexEntry.html">IndexEntry</a></div><div class="ttdoc">Single index entry describing a block's type, (optional) data classification, and file offset.</div><div class="ttdef"><b>Definition</b> <a href="index_8h_source.html#l00108">index.h:109</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html"><div class="ttname"><a href="structaaru__options.html">aaru_options</a></div><div class="ttdoc">Parsed user-specified tunables controlling compression, deduplication, hashing and DDT geometry.</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00216">options.h:217</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_a2d62d4cd6f1e59c145e3c4bc621f7d43"><div class="ttname"><a href="structaaru__options.html#a2d62d4cd6f1e59c145e3c4bc621f7d43">aaru_options::deduplicate</a></div><div class="ttdeci">bool deduplicate</div><div class="ttdoc">Storage dedup flag (DDT always exists).</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00219">options.h:219</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_a3b6341d5cbd1ed2c4ff0686cd88de753"><div class="ttname"><a href="structaaru__options.html#a3b6341d5cbd1ed2c4ff0686cd88de753">aaru_options::data_shift</a></div><div class="ttdeci">uint8_t data_shift</div><div class="ttdoc">Global data shift: low bits encode sector offset inside a block (2^data_shift span).</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00223">options.h:223</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_a471cdd9988e95b36ee132cd047576237"><div class="ttname"><a href="structaaru__options.html#a471cdd9988e95b36ee132cd047576237">aaru_options::dictionary</a></div><div class="ttdeci">uint32_t dictionary</div><div class="ttdoc">LZMA dictionary size in bytes (>= 4096 recommended). Default: 33554432 (32 MiB).</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00221">options.h:221</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_a4db2ac219f4d13ff2c35b8d62babaca2"><div class="ttname"><a href="structaaru__options.html#a4db2ac219f4d13ff2c35b8d62babaca2">aaru_options::compress</a></div><div class="ttdeci">bool compress</div><div class="ttdoc">Enable adaptive compression (LZMA for data blocks, FLAC for audio). Default: true.</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00218">options.h:218</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_a522d922c2ab6e04ce8e7051aaf953093"><div class="ttname"><a href="structaaru__options.html#a522d922c2ab6e04ce8e7051aaf953093">aaru_options::sha256</a></div><div class="ttdeci">bool sha256</div><div class="ttdoc">Generate SHA-256 checksum (ChecksumAlgorithm::Sha256) when finalizing image.</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00227">options.h:227</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_a623a984dfec7abd375e7ef3d97333a4f"><div class="ttname"><a href="structaaru__options.html#a623a984dfec7abd375e7ef3d97333a4f">aaru_options::spamsum</a></div><div class="ttdeci">bool spamsum</div><div class="ttdoc">Generate SpamSum fuzzy hash (ChecksumAlgorithm::SpamSum) if enabled.</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00229">options.h:229</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_a8b82ce71c52cc737f7b73334e094a795"><div class="ttname"><a href="structaaru__options.html#a8b82ce71c52cc737f7b73334e094a795">aaru_options::table_shift</a></div><div class="ttdeci">int8_t table_shift</div><div class="ttdoc">DDT table shift (multi-level fan-out exponent). Default: heuristically calculated.</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00222">options.h:222</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_a93c09eed5b0613fa25dd84c7d3c2a416"><div class="ttname"><a href="structaaru__options.html#a93c09eed5b0613fa25dd84c7d3c2a416">aaru_options::md5</a></div><div class="ttdeci">bool md5</div><div class="ttdoc">Generate MD5 checksum (ChecksumAlgorithm::Md5) when finalizing image.</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00225">options.h:225</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_abfbdc9267e6db5222e04ffd5a963b3a7"><div class="ttname"><a href="structaaru__options.html#abfbdc9267e6db5222e04ffd5a963b3a7">aaru_options::blake3</a></div><div class="ttdeci">bool blake3</div><div class="ttdoc">Generate BLAKE3 checksum if supported (not stored if algorithm unavailable).</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00228">options.h:228</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_ae3ff963481af06c7e097bdaa0c925bb6"><div class="ttname"><a href="structaaru__options.html#ae3ff963481af06c7e097bdaa0c925bb6">aaru_options::sha1</a></div><div class="ttdeci">bool sha1</div><div class="ttdoc">Generate SHA-1 checksum (ChecksumAlgorithm::Sha1) when finalizing image.</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00226">options.h:226</a></div></div>
|
||
<div class="ttc" id="astructaaru__options_html_aea2e536712f73ad12dcca704b47dc48c"><div class="ttname"><a href="structaaru__options.html#aea2e536712f73ad12dcca704b47dc48c">aaru_options::block_alignment</a></div><div class="ttdeci">uint8_t block_alignment</div><div class="ttdoc">log2 underlying block alignment (2^n bytes). Default: 9 (512 bytes).</div><div class="ttdef"><b>Definition</b> <a href="options_8h_source.html#l00224">options.h:224</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html"><div class="ttname"><a href="structaaruformat__context.html">aaruformat_context</a></div><div class="ttdoc">Master context representing an open or in‑creation Aaru image.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00171">context.h:172</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a04c5fb367458a6e9dd0a50b39f6edec2"><div class="ttname"><a href="structaaruformat__context.html#a04c5fb367458a6e9dd0a50b39f6edec2">aaruformat_context::user_data_ddt_header</a></div><div class="ttdeci">DdtHeader2 user_data_ddt_header</div><div class="ttdoc">Active user data DDT v2 header (primary table meta).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00189">context.h:189</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a09177c9e68d054bab844305f2771b77a"><div class="ttname"><a href="structaaruformat__context.html#a09177c9e68d054bab844305f2771b77a">aaruformat_context::library_major_version</a></div><div class="ttdeci">uint8_t library_major_version</div><div class="ttdoc">Linked library major version.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00177">context.h:177</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a0d06526ba707ed15763457e53a00673d"><div class="ttname"><a href="structaaruformat__context.html#a0d06526ba707ed15763457e53a00673d">aaruformat_context::dirty_checksum_block</a></div><div class="ttdeci">bool dirty_checksum_block</div><div class="ttdoc">True if checksum block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00311">context.h:311</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a0d4e1977913ce67e85bced41c58e5dd2"><div class="ttname"><a href="structaaruformat__context.html#a0d4e1977913ce67e85bced41c58e5dd2">aaruformat_context::deduplicate</a></div><div class="ttdeci">bool deduplicate</div><div class="ttdoc">Storage deduplication active (duplicates coalesce).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00299">context.h:299</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a130daf19dbed426f1c4c6f82691bc054"><div class="ttname"><a href="structaaruformat__context.html#a130daf19dbed426f1c4c6f82691bc054">aaruformat_context::compression_enabled</a></div><div class="ttdeci">bool compression_enabled</div><div class="ttdoc">True if block compression enabled (writing path).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00300">context.h:300</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a1387f95c2da152594f29c5c276e5dbc5"><div class="ttname"><a href="structaaruformat__context.html#a1387f95c2da152594f29c5c276e5dbc5">aaruformat_context::last_written_block</a></div><div class="ttdeci">uint64_t last_written_block</div><div class="ttdoc">Last written block number (write path).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00283">context.h:283</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a182f0f2c49aeb3b2f4ed8e7625d1cf46"><div class="ttname"><a href="structaaruformat__context.html#a182f0f2c49aeb3b2f4ed8e7625d1cf46">aaruformat_context::dirty_media_tags</a></div><div class="ttdeci">bool dirty_media_tags</div><div class="ttdoc">True if media tags should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00321">context.h:321</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a18bee1dd72fd1ca4957ff6ddfebce343"><div class="ttname"><a href="structaaruformat__context.html#a18bee1dd72fd1ca4957ff6ddfebce343">aaruformat_context::sector_hash_map</a></div><div class="ttdeci">hash_map_t * sector_hash_map</div><div class="ttdoc">Deduplication hash map (fingerprint->entry mapping).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00253">context.h:253</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a21dffad51cfb58f5f71f7babee2aaceb"><div class="ttname"><a href="structaaruformat__context.html#a21dffad51cfb58f5f71f7babee2aaceb">aaruformat_context::sha256_context</a></div><div class="ttdeci">sha256_ctx sha256_context</div><div class="ttdoc">Opaque SHA-256 context for streaming updates.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00272">context.h:272</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a2e2c23ecc1d15087ef46e2591c47194a"><div class="ttname"><a href="structaaruformat__context.html#a2e2c23ecc1d15087ef46e2591c47194a">aaruformat_context::calculating_sha256</a></div><div class="ttdeci">bool calculating_sha256</div><div class="ttdoc">True if whole-image SHA-256 being calculated on-the-fly.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00275">context.h:275</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a2f095c3433eb29d2bf421b1e3355e72d"><div class="ttname"><a href="structaaruformat__context.html#a2f095c3433eb29d2bf421b1e3355e72d">aaruformat_context::dirty_primary_ddt</a></div><div class="ttdeci">bool dirty_primary_ddt</div><div class="ttdoc">True if primary DDT table should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00309">context.h:309</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a3a12addf4a338cc04471709604d48ae1"><div class="ttname"><a href="structaaruformat__context.html#a3a12addf4a338cc04471709604d48ae1">aaruformat_context::block_header_cache</a></div><div class="ttdeci">struct CacheHeader block_header_cache</div><div class="ttdoc">LRU/Cache header for block headers.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00256">context.h:256</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a3c44b0cbcfb4586ce666dcd97a3dd85a"><div class="ttname"><a href="structaaruformat__context.html#a3c44b0cbcfb4586ce666dcd97a3dd85a">aaruformat_context::md5_context</a></div><div class="ttdeci">md5_ctx md5_context</div><div class="ttdoc">Opaque MD5 context for streaming updates.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00270">context.h:270</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a3c6d8057776a41c478df60ee228b2cf4"><div class="ttname"><a href="structaaruformat__context.html#a3c6d8057776a41c478df60ee228b2cf4">aaruformat_context::dirty_sector_suffix_block</a></div><div class="ttdeci">bool dirty_sector_suffix_block</div><div class="ttdoc">True if sector suffix block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00316">context.h:316</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a3c7b902731274622296d04564b193b64"><div class="ttname"><a href="structaaruformat__context.html#a3c7b902731274622296d04564b193b64">aaruformat_context::user_data_ddt2</a></div><div class="ttdeci">uint64_t * user_data_ddt2</div><div class="ttdoc">DDT entries (big variant) primary/secondary current.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00187">context.h:187</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a4023f622bac759754c68ac633c53e3f4"><div class="ttname"><a href="structaaruformat__context.html#a4023f622bac759754c68ac633c53e3f4">aaruformat_context::shift</a></div><div class="ttdeci">uint8_t shift</div><div class="ttdoc">Legacy overall shift (deprecated by data_shift/table_shift).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00195">context.h:195</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a43de9f79e2d7063d5f120c63301800e3"><div class="ttname"><a href="structaaruformat__context.html#a43de9f79e2d7063d5f120c63301800e3">aaruformat_context::dirty_dvd_title_key_decrypted_block</a></div><div class="ttdeci">bool dirty_dvd_title_key_decrypted_block</div><div class="ttdoc">True if decrypted title key block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00320">context.h:320</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a47b4ad72f562022ffac686c59b33057f"><div class="ttname"><a href="structaaruformat__context.html#a47b4ad72f562022ffac686c59b33057f">aaruformat_context::dirty_mode2_subheaders_block</a></div><div class="ttdeci">bool dirty_mode2_subheaders_block</div><div class="ttdoc">True if MODE2 subheader block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00313">context.h:313</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a482f84e538a27a4b8686ad27c449bee9"><div class="ttname"><a href="structaaruformat__context.html#a482f84e538a27a4b8686ad27c449bee9">aaruformat_context::dirty_tape_partition_block</a></div><div class="ttdeci">bool dirty_tape_partition_block</div><div class="ttdoc">True if tape partition block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00324">context.h:324</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a4bdcfa521eb92c949081adca481f01fd"><div class="ttname"><a href="structaaruformat__context.html#a4bdcfa521eb92c949081adca481f01fd">aaruformat_context::dirty_cicm_block</a></div><div class="ttdeci">bool dirty_cicm_block</div><div class="ttdoc">True if CICM metadata block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00328">context.h:328</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a4d514102386b48bd51ac82c27bf9920a"><div class="ttname"><a href="structaaruformat__context.html#a4d514102386b48bd51ac82c27bf9920a">aaruformat_context::is_tape</a></div><div class="ttdeci">bool is_tape</div><div class="ttdoc">True if the image is a tape image.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00305">context.h:305</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a4e4c12388d90a11cf14266d1215ce13e"><div class="ttname"><a href="structaaruformat__context.html#a4e4c12388d90a11cf14266d1215ce13e">aaruformat_context::calculating_sha1</a></div><div class="ttdeci">bool calculating_sha1</div><div class="ttdoc">True if whole-image SHA-1 being calculated on-the-fly.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00274">context.h:274</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a4f10051f78c63709ccc01cca3ba5a22f"><div class="ttname"><a href="structaaruformat__context.html#a4f10051f78c63709ccc01cca3ba5a22f">aaruformat_context::dirty_tracks_block</a></div><div class="ttdeci">bool dirty_tracks_block</div><div class="ttdoc">True if tracks block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00312">context.h:312</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a510b72290e2bd50e02ef8a2387aa829d"><div class="ttname"><a href="structaaruformat__context.html#a510b72290e2bd50e02ef8a2387aa829d">aaruformat_context::ecc_cd_context</a></div><div class="ttdeci">CdEccContext * ecc_cd_context</div><div class="ttdoc">CD ECC/EDC helper tables (allocated on demand).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00248">context.h:248</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a551d4fb5a3213106d01d369e98bdf3c8"><div class="ttname"><a href="structaaruformat__context.html#a551d4fb5a3213106d01d369e98bdf3c8">aaruformat_context::rewinded</a></div><div class="ttdeci">bool rewinded</div><div class="ttdoc">True if stream has been rewound after open (write path).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00293">context.h:293</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a58359ec8607d1d10e0af8699be238e77"><div class="ttname"><a href="structaaruformat__context.html#a58359ec8607d1d10e0af8699be238e77">aaruformat_context::block_cache</a></div><div class="ttdeci">struct CacheHeader block_cache</div><div class="ttdoc">LRU/Cache header for block payloads.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00257">context.h:257</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a60a07b295752e19284649743c43122c2"><div class="ttname"><a href="structaaruformat__context.html#a60a07b295752e19284649743c43122c2">aaruformat_context::dirty_sector_prefix_block</a></div><div class="ttdeci">bool dirty_sector_prefix_block</div><div class="ttdoc">True if sector prefix block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00314">context.h:314</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a62885cab6ef674fd27b4de32ab4ee346"><div class="ttname"><a href="structaaruformat__context.html#a62885cab6ef674fd27b4de32ab4ee346">aaruformat_context::in_memory_ddt</a></div><div class="ttdeci">bool in_memory_ddt</div><div class="ttdoc">True if primary (and possibly secondary) DDT loaded.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00196">context.h:196</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a63616c8450e9e1853e0645714fe310cb"><div class="ttname"><a href="structaaruformat__context.html#a63616c8450e9e1853e0645714fe310cb">aaruformat_context::dirty_index_block</a></div><div class="ttdeci">bool dirty_index_block</div><div class="ttdoc">True if index block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00330">context.h:330</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a670dec8d59407989fefc361dc26c6832"><div class="ttname"><a href="structaaruformat__context.html#a670dec8d59407989fefc361dc26c6832">aaruformat_context::header</a></div><div class="ttdeci">AaruHeaderV2 header</div><div class="ttdoc">Parsed container header (v2).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00175">context.h:175</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a6f3db4b3d6f4351edae1353b0815795e"><div class="ttname"><a href="structaaruformat__context.html#a6f3db4b3d6f4351edae1353b0815795e">aaruformat_context::dirty_json_block</a></div><div class="ttdeci">bool dirty_json_block</div><div class="ttdoc">True if JSON metadata block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00329">context.h:329</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a6f61f9ea20f4e3b791a0d6388dd43651"><div class="ttname"><a href="structaaruformat__context.html#a6f61f9ea20f4e3b791a0d6388dd43651">aaruformat_context::is_writing</a></div><div class="ttdeci">bool is_writing</div><div class="ttdoc">True if context opened/created for writing.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00292">context.h:292</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a705ef2714c4773514c23a56371f42a0f"><div class="ttname"><a href="structaaruformat__context.html#a705ef2714c4773514c23a56371f42a0f">aaruformat_context::tape_ddt</a></div><div class="ttdeci">TapeDdtHashEntry * tape_ddt</div><div class="ttdoc">Hash table root for tape DDT entries.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00182">context.h:182</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a729b87257c0b5d1e9abf1af133a4b0f3"><div class="ttname"><a href="structaaruformat__context.html#a729b87257c0b5d1e9abf1af133a4b0f3">aaruformat_context::spamsum_context</a></div><div class="ttdeci">spamsum_ctx * spamsum_context</div><div class="ttdoc">Opaque SpamSum context for streaming updates.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00267">context.h:267</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a7ae2128b4ae5511c2c601ec8e8f66387"><div class="ttname"><a href="structaaruformat__context.html#a7ae2128b4ae5511c2c601ec8e8f66387">aaruformat_context::dirty_single_level_ddt</a></div><div class="ttdeci">bool dirty_single_level_ddt</div><div class="ttdoc">True if single-level DDT should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00310">context.h:310</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a7dc0a0fe0bf6223ff4587fd01c360b76"><div class="ttname"><a href="structaaruformat__context.html#a7dc0a0fe0bf6223ff4587fd01c360b76">aaruformat_context::magic</a></div><div class="ttdeci">uint64_t magic</div><div class="ttdoc">File magic (AARU_MAGIC) post-open.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00174">context.h:174</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a865120510888fac8bb3597b57d515ba7"><div class="ttname"><a href="structaaruformat__context.html#a865120510888fac8bb3597b57d515ba7">aaruformat_context::calculating_spamsum</a></div><div class="ttdeci">bool calculating_spamsum</div><div class="ttdoc">True if whole-image SpamSum being calculated on-the-fly.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00276">context.h:276</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a88effb2eb082320b5b31d729981cf2d4"><div class="ttname"><a href="structaaruformat__context.html#a88effb2eb082320b5b31d729981cf2d4">aaruformat_context::primary_ddt_offset</a></div><div class="ttdeci">uint64_t primary_ddt_offset</div><div class="ttdoc">File offset of the primary DDT v2 table.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00192">context.h:192</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a8b89a7e0e6369dad38e23dabaf4b49a4"><div class="ttname"><a href="structaaruformat__context.html#a8b89a7e0e6369dad38e23dabaf4b49a4">aaruformat_context::blake3_context</a></div><div class="ttdeci">blake3_hasher * blake3_context</div><div class="ttdoc">Opaque BLAKE3 context for streaming updates.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00268">context.h:268</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a8be6dd9da00d771d24c7a6295f1c1d02"><div class="ttname"><a href="structaaruformat__context.html#a8be6dd9da00d771d24c7a6295f1c1d02">aaruformat_context::calculating_blake3</a></div><div class="ttdeci">bool calculating_blake3</div><div class="ttdoc">True if whole-image BLAKE3 being calculated on-the-fly.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00277">context.h:277</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a8fb7db933d8abfeb20a28110cb258922"><div class="ttname"><a href="structaaruformat__context.html#a8fb7db933d8abfeb20a28110cb258922">aaruformat_context::library_minor_version</a></div><div class="ttdeci">uint8_t library_minor_version</div><div class="ttdoc">Linked library minor version;.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00178">context.h:178</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a939b702f75e80062bc635add4c3ab142"><div class="ttname"><a href="structaaruformat__context.html#a939b702f75e80062bc635add4c3ab142">aaruformat_context::next_block_position</a></div><div class="ttdeci">uint64_t next_block_position</div><div class="ttdoc">Absolute file offset where next block will be written.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00282">context.h:282</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a95770f959cae3b6b34e2b1ae592a7136"><div class="ttname"><a href="structaaruformat__context.html#a95770f959cae3b6b34e2b1ae592a7136">aaruformat_context::calculating_md5</a></div><div class="ttdeci">bool calculating_md5</div><div class="ttdoc">True if whole-image MD5 being calculated on-the-fly.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00273">context.h:273</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_a9755effb4c78f872b840c62566fa6e4a"><div class="ttname"><a href="structaaruformat__context.html#a9755effb4c78f872b840c62566fa6e4a">aaruformat_context::dirty_sector_suffix_ddt</a></div><div class="ttdeci">bool dirty_sector_suffix_ddt</div><div class="ttdoc">True if sector suffix DDT should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00317">context.h:317</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_aa9fb206d36b68370f2435899c79abbfd"><div class="ttname"><a href="structaaruformat__context.html#aa9fb206d36b68370f2435899c79abbfd">aaruformat_context::dirty_dumphw_block</a></div><div class="ttdeci">bool dirty_dumphw_block</div><div class="ttdoc">True if dump hardware block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00327">context.h:327</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_aab573afda1087dcc99dc9a6a34fcc844"><div class="ttname"><a href="structaaruformat__context.html#aab573afda1087dcc99dc9a6a34fcc844">aaruformat_context::dirty_metadata_block</a></div><div class="ttdeci">bool dirty_metadata_block</div><div class="ttdoc">True if metadata block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00326">context.h:326</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ab268908ef1517931e68c19f9ddd63269"><div class="ttname"><a href="structaaruformat__context.html#ab268908ef1517931e68c19f9ddd63269">aaruformat_context::dirty_sector_subchannel_block</a></div><div class="ttdeci">bool dirty_sector_subchannel_block</div><div class="ttdoc">True if subchannel block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00318">context.h:318</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ab516fae594bde4f76b75488d0a3ca3a8"><div class="ttname"><a href="structaaruformat__context.html#ab516fae594bde4f76b75488d0a3ca3a8">aaruformat_context::imageStream</a></div><div class="ttdeci">FILE * imageStream</div><div class="ttdoc">Underlying FILE* stream (binary mode).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00176">context.h:176</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ab5aef7d04dd9d157b63e0aad49408e8b"><div class="ttname"><a href="structaaruformat__context.html#ab5aef7d04dd9d157b63e0aad49408e8b">aaruformat_context::dirty_dvd_long_sector_blocks</a></div><div class="ttdeci">bool dirty_dvd_long_sector_blocks</div><div class="ttdoc">True if DVD long sector blocks should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00319">context.h:319</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ab977bf7c003408fa90116d1b441780ea"><div class="ttname"><a href="structaaruformat__context.html#ab977bf7c003408fa90116d1b441780ea">aaruformat_context::dirty_sector_prefix_ddt</a></div><div class="ttdeci">bool dirty_sector_prefix_ddt</div><div class="ttdoc">True if sector prefix DDT should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00315">context.h:315</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ab97a719a5b4186695b67143db7376152"><div class="ttname"><a href="structaaruformat__context.html#ab97a719a5b4186695b67143db7376152">aaruformat_context::index_entries</a></div><div class="ttdeci">UT_array * index_entries</div><div class="ttdoc">Flattened index entries (UT_array of IndexEntry).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00252">context.h:252</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_abdf9ca4ea03bb2080831fc9aaa127422"><div class="ttname"><a href="structaaruformat__context.html#abdf9ca4ea03bb2080831fc9aaa127422">aaruformat_context::dirty_tape_file_block</a></div><div class="ttdeci">bool dirty_tape_file_block</div><div class="ttdoc">True if tape file block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00323">context.h:323</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ac970291b3449c04221827b9c2c18ac70"><div class="ttname"><a href="structaaruformat__context.html#ac970291b3449c04221827b9c2c18ac70">aaruformat_context::image_info</a></div><div class="ttdeci">ImageInfo image_info</div><div class="ttdoc">Exposed high-level image info summary.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00260">context.h:260</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ad1e28bac5a6c9bfdb8d18793686fc755"><div class="ttname"><a href="structaaruformat__context.html#ad1e28bac5a6c9bfdb8d18793686fc755">aaruformat_context::sha1_context</a></div><div class="ttdeci">sha1_ctx sha1_context</div><div class="ttdoc">Opaque SHA-1 context for streaming updates.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00271">context.h:271</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ad1e4ceb44652cacfc63e0e2c95f570c6"><div class="ttname"><a href="structaaruformat__context.html#ad1e4ceb44652cacfc63e0e2c95f570c6">aaruformat_context::dirty_secondary_ddt</a></div><div class="ttdeci">bool dirty_secondary_ddt</div><div class="ttdoc">True if secondary DDT tables should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00308">context.h:308</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ad3d5494e23b07418e9fbd22c3771e534"><div class="ttname"><a href="structaaruformat__context.html#ad3d5494e23b07418e9fbd22c3771e534">aaruformat_context::readableSectorTags</a></div><div class="ttdeci">bool * readableSectorTags</div><div class="ttdoc">Per-sector boolean array (optical tags read successfully?).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00263">context.h:263</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_ad5e046ffc70066ba070dc58514b3a771"><div class="ttname"><a href="structaaruformat__context.html#ad5e046ffc70066ba070dc58514b3a771">aaruformat_context::dirty_tape_ddt</a></div><div class="ttdeci">bool dirty_tape_ddt</div><div class="ttdoc">True if tape DDT should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00322">context.h:322</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_adc67f6a6ef1602648bb064d47eb1fe88"><div class="ttname"><a href="structaaruformat__context.html#adc67f6a6ef1602648bb064d47eb1fe88">aaruformat_context::lzma_dict_size</a></div><div class="ttdeci">uint32_t lzma_dict_size</div><div class="ttdoc">LZMA dictionary size (writing path).</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00298">context.h:298</a></div></div>
|
||
<div class="ttc" id="astructaaruformat__context_html_aeb85241fdc8a4ac27aee8acab5ceec17"><div class="ttname"><a href="structaaruformat__context.html#aeb85241fdc8a4ac27aee8acab5ceec17">aaruformat_context::dirty_geometry_block</a></div><div class="ttdeci">bool dirty_geometry_block</div><div class="ttdoc">True if geometry block should be written during close.</div><div class="ttdef"><b>Definition</b> <a href="context_8h_source.html#l00325">context.h:325</a></div></div>
|
||
</div><!-- fragment --></div><!-- contents -->
|
||
</div><!-- doc-content -->
|
||
</div><!-- container -->
|
||
<!-- start footer part -->
|
||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||
<ul>
|
||
<li class="navelem"><a href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a href="create_8c.html">create.c</a></li>
|
||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.14.0 </li>
|
||
</ul>
|
||
</div>
|
||
</body>
|
||
</html>
|