On Tue, Jul 29, 2014 at 1:37 AM, Staven <pvl.sta...@gmail.com> wrote:
>
>       width = (hdr[9] << 24) | (hdr[10] << 16) | (hdr[11] << 8) | hdr[12]
>       height = (hdr[13] << 24) | (hdr[14] << 16) | (hdr[15] << 8) | hdr[16]
>


To reiterate this, each of these parenthesized expressions is in
native byte order *already*, if I understand the C standard correctly,
and ntohl/htonl would only have any impact if we bit off the whole
word in one byte. Pleasee don't make a mess with both of these
functions.

cheers!
mar77i

Reply via email to