From 2e83cf4e89a170f13965e1fe801761016052fa7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Thu, 13 Dec 2007 16:26:53 +0100 Subject: Use FOURCC comparison rather than multiple bytes comparison. --HG-- extra : transplant_source : D%BF%D7%DA%B0%F7%15%1A%96%2BV%DB%BF%85%05%AF%11%85%9B%1E --- src/demuxers/demux_flv.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src') diff --git a/src/demuxers/demux_flv.c b/src/demuxers/demux_flv.c index 99c861e0d..f0b29532b 100644 --- a/src/demuxers/demux_flv.c +++ b/src/demuxers/demux_flv.c @@ -684,8 +684,7 @@ static void seek_flv_file(demux_flv_t *this, off_t seek_pos, int seek_pts) { return; } /* check StreamID and CodecID */ - if (buf[0] == 0 && buf[1] == 0 && buf[2] == 0 && - buf[3] == (this->videocodec | 0x10)) { + if ( _X_ME_32(buf) == ME_FOURCC(0, 0, 0, (this->videocodec | 0x10)) ) { this->input->seek(this->input, -16, SEEK_CUR); lprintf(" ...resynced after %d bytes\n", i); return; -- cgit v1.2.3