Length of a BYTE array in C++
<p>I have a program in C++ that has a BYTE array that stores some values. I need to find the length of that array i.e. number of bytes in that array. Please help me in this regard.</p>

<p>This is the code:</p>

<pre><code>BYTE *res;
res = (BYTE *)realloc(res, (byte_len(res)+2));
</code></pre>

<p><code>byte_len</code> is a fictitious function that returns the length of the BYTE array and I would like to know how to implement it.</p>
