1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2<html>
3
4<head>
5<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
6<META http-equiv="Content-Style-Type" content="text/css">
7<LINK rel="stylesheet" type="text/css" href="../CSS/revolution.css">
8<title>NANDClose</title>
9</head>
10
11<body>
12
13<h1>NANDClose</h1>
14
15<h2>Syntax</h2>
16<dl><dd><pre class="construction">#include &lt;revolution/nand.h&gt;
17
18s32 NANDClose(NANDFileInfo *info);
19</pre></dd></dl>
20
21<h2>Arguments</h2>
22<p>
23<TABLE class="arguments" border="1" >
24  <tr>
25<TH>info</TH>
26<TD>Pointer to a <CODE>NANDFileInfo</CODE> structure</TD>
27  </tr>
28</TABLE>
29</p>
30
31<h2>Return Values</h2>
32<p>
33Returns one of the following codes.
34<p>
35<code>NAND_RESULT_OK<br> NAND_RESULT_ACCESS<br> NAND_RESULT_ALLOC_FAILED<br> NAND_RESULT_BUSY<br> NAND_RESULT_CORRUPT<br> NAND_RESULT_INVALID<br> NAND_RESULT_UNKNOWN<br> NAND_RESULT_FATAL_ERROR<br></code>
36</p>
37</p>
38
39<H2>Description</H2>
40<p>
41Closes a file.
42</p>
43
44<p>
45This function sometimes puts the current thread to sleep, so it cannot be called from callback functions. For precautions when calling similar functions, refer to <a href="../os/Interrupt/intro.html">Interrupts and Callback Functions</a>.
46</p>
47
48<p>
49This function updates the Wii console NAND memory's FAT. However, updating does not take place if a file is being closed and no data has been written to the files in Wii console NAND memory since the last time the FAT was updated.
50</p>
51
52<h2>See Also</h2>
53<p class="reference">
54<a href="./NANDOpen.html">NANDOpen</a><BR><a href="./NANDOpenAsync.html">NANDOpenAsync</a><BR><a href="./NANDCloseAsync.html">NANDCloseAsync</a><BR><a href="../os/Interrupt/intro.html">Interrupts and Callback Functions</a>
55</p>
56
57<H2>Revision History</H2>
58<p>
592009/12/02 Added information about updating the FAT.<br>2008/04/23 Added mention of updating the FAT.<br>2007/09/25 Added information on the sleep status of threads.<br>2006/11/30 Added the <CODE>NAND_RESULT_ALLOC_FAILED</CODE> and <CODE>NAND_RESULT_BUSY</CODE> codes.<br>2006/06/16 Initial version.<BR>
60</p>
61
62<hr><p>CONFIDENTIAL</p></body>
63</html>