diff options
Diffstat (limited to 'src/demuxers/demux_aac.c')
-rw-r--r-- | src/demuxers/demux_aac.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/demuxers/demux_aac.c b/src/demuxers/demux_aac.c index e6467ecd9..4076cc2e0 100644 --- a/src/demuxers/demux_aac.c +++ b/src/demuxers/demux_aac.c @@ -91,7 +91,7 @@ static int open_aac_file(demux_aac_t *this) { return 0; /* Check for an ADIF header - should be at the start of the file */ - if ( signature == ME_FOURCC('A', 'D', 'I', 'F') ) { + if (_x_is_fourcc(peak, "AIDF")) { lprintf("found ADIF header\n"); return 1; } @@ -128,9 +128,7 @@ static int open_aac_file(demux_aac_t *this) { if ((frame_size > 0) && (data_start+frame_size < MAX_PREVIEW_SIZE-1) && /* first 28 bits must be identical */ - (peak[data_start ] ==peak[data_start+frame_size ]) && - (peak[data_start+1] ==peak[data_start+frame_size+1]) && - (peak[data_start+2] ==peak[data_start+frame_size+2]) && + memcmp(&peak[data_start], &peak[data_start+frame_size], 4) == 0 && (peak[data_start+3]>>4==peak[data_start+frame_size+3]>>4)) { lprintf("found second ADTS header\n"); |