From: Thibaut M. <tma...@us...> - 2003-10-11 21:25:11
|
Update of /cvsroot/xine/xine-lib/src/demuxers In directory sc8-pr-cvs1:/tmp/cvs-serv11453 Modified Files: demux_asf.c Log Message: use bswap.h Index: demux_asf.c =================================================================== RCS file: /cvsroot/xine/xine-lib/src/demuxers/demux_asf.c,v retrieving revision 1.131 retrieving revision 1.132 diff -u -r1.131 -r1.132 --- demux_asf.c 8 Oct 2003 22:53:17 -0000 1.131 +++ demux_asf.c 11 Oct 2003 21:25:04 -0000 1.132 @@ -42,6 +42,7 @@ #include "xine_internal.h" #include "demux.h" #include "xineutils.h" +#include "bswap.h" #include "asfheader.h" #include "xmlparser.h" @@ -198,7 +199,7 @@ this->status = DEMUX_FINISHED; } - return buf[0] | (buf[1] << 8); + return LE_16(buf); } static uint32_t get_le32 (demux_asf_t *this) { @@ -216,7 +217,7 @@ this->status = DEMUX_FINISHED; } - return buf[0] | (buf[1] << 8) | (buf[2] << 16) | (buf[3] << 24); + return LE_32(buf); } static uint64_t get_le64 (demux_asf_t *this) { @@ -232,14 +233,7 @@ this->status = DEMUX_FINISHED; } - return (uint64_t) buf[0] - | ((uint64_t) buf[1] << 8) - | ((uint64_t) buf[2] << 16) - | ((uint64_t) buf[3] << 24) - | ((uint64_t) buf[4] << 32) - | ((uint64_t) buf[5] << 40) - | ((uint64_t) buf[6] << 48) - | ((uint64_t) buf[7] << 56) ; + return LE_64(buf); } static int get_guid (demux_asf_t *this) { |