[MPlayer-dev-eng] Solaris patches
Uoti Urpala
uoti.urpala at pp1.inet.fi
Mon Sep 4 14:42:53 CEST 2006
On Mon, 2006-09-04 at 14:08 +0200, Michael Niedermayer wrote:
> On Sun, Sep 03, 2006 at 02:49:27PM +0100, Robin KAY wrote:
> > I initially just used ptr[0] | (ptr[1] << 1),
>
> you mean ptr[0] | (ptr[1] << 8) ?
>
>
> > but then I saw the
> > memcpy(3C) method was used elsewhere in asfheader.c. I imagine this was
> > done to make the code portable to systems with non-octet chars.
>
> IIRC sizeof(char) = 1 per c standard
The standard does guarantee that sizeof(char)==1, but not that there are
8 bits per char. However in practice worrying about that is pointless,
and MPlayer does not try to be portable to systems with non-8bit chars.
Also the shift version should still be correct on such platforms since
the input is presumably still a normal file with 8 bits per char.
More information about the MPlayer-dev-eng
mailing list