Hello, I have the following pseudo code that I am trying to implement in Java. My issue is the pseudo code seems to be heavily C based and my C is very rusty. Could someone help me understand the following function?
uint theFunction(BYTE* header)
{
UINT length;
header = header + 1;
length = ((UINT16) header[0]) | ((UINT16) header[1] << 8);
return length;
}
My issues are mostly with the understanding of the header = header + 1;
and the length = ((UINT16) header[0]) | ((UINT16) header[1] << 8);
. I am assuming the header pointer is increasing to the 2nd byte and then the 3rd and 4th bytes are being or'd together after shifting the 4th...