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=windows-1252">
6<META http-equiv="Content-Style-Type" content="text/css">
7<META name="GENERATOR" content="IBM WebSphere Studio Homepage Builder Version 7.0.0.0 for Windows">
8<title>DWC_ReallocEx</title>
9<LINK rel="stylesheet" href="../css/nitro.css" type="text/css">
10</head>
11
12<body>
13<a name="dwc__memfunc_8h_1100d1fa8c69d8434b1d2b06946d529df"></a>
14<h1 align="left">DWC_ReallocEx</h1>
15<h2>Syntax</h2>
16
17<dl>
18  <dd>
19<CODE>#include &lt;dwc.h&gt;</CODE><BR>
20  <BR>
21  <PRE><CODE>void* <a href=DWC_ReallocEx.html#dwc__memfunc_8h_1100d1fa8c69d8434b1d2b06946d529df>DWC_ReallocEx</a>(DWCAllocType name,
22                    void *ptr,
23                    u32 oldsize,
24                    u32 newsize,
25                    int align);</CODE></PRE></dd>
26</dl>
27
28<h2>Arguments</h2>
29
30<TABLE border="1" width="100%">
31  <TBODY>
32
33    <TR>
34<TD width="13%"><EM><STRONG>name</STRONG></EM></TD>
35<TD width="87%">Information for library development. Specify 0.</TD>
36    </TR>
37
38    <TR>
39<TD width="13%"><EM><STRONG>ptr</STRONG></EM></TD>
40<TD width="87%">Pointer to the memory allocated using the memory allocation function specified by the <a href=DWC_Init.html><CODE>DWC_Init</CODE></a> function.</TD>
41    </TR>
42
43    <TR>
44<TD width="13%"><EM><STRONG>oldsize</STRONG></EM></TD>
45<TD width="87%">Information for library development. Specify 0.</TD>
46    </TR>
47
48    <TR>
49<TD width="13%"><EM><STRONG>newsize</STRONG></EM></TD>
50<TD width="87%">Memory size (in bytes) after making the change.</TD>
51    </TR>
52
53    <TR>
54<TD width="13%"><EM><STRONG>align</STRONG></EM></TD>
55<TD width="87%">Alignment (in bytes) of the memory to be reserved. This is passed to the memory allocation function that was set using the <CODE><a href=DWC_Init.html>DWC_Init</a></CODE> function.</TD>
56    </TR>
57
58  </TBODY>
59</TABLE>
60
61<h2>Return Values</h2>
62
63<p>Returns a pointer to the memory newly allocated using the memory allocation function specified by <a href=DWC_Init.html><CODE>DWC_Init</CODE></a>.</p>
64
65<H2>Description</H2>
66<p>Moves and changes the size of the memory allocated using the memory allocation function specified by <a href=DWC_Init.html><CODE>DWC_Init</CODE></a>.</p><p>Once memory of a new size has been reserved in a different region, the library internally releases the original memory. The newly-released memory is not initialized.</p><p>When the <a href=DWC_ReallocEx.html#dwc__memfunc_8h_1100d1fa8c69d8434b1d2b06946d529df>DWC_ReallocEx</a> function is used, the <CODE>align</CODE> argument from this function is passed to the <CODE>align</CODE> argument in the memory allocation function.</p>
67
68<H2>Revision History</H2>
69<DL>
70
71<DT><para>1.2.1</DT>
72<DD>Changed so that newly-released memory will not be initialized.</DD>
73
74</DL>
75<hr><p>CONFIDENTIAL</p></body>
76</html>
77