[MPlayer-cvslog] r36892 - trunk/libmpdemux/aac_hdr.c

reimar subversion at mplayerhq.hu
Thu Feb 20 00:01:10 CET 2014


Author: reimar
Date: Thu Feb 20 00:01:10 2014
New Revision: 36892

Log:
aac_hdr: remove variable to fix warning, add const.

Modified:
   trunk/libmpdemux/aac_hdr.c

Modified: trunk/libmpdemux/aac_hdr.c
==============================================================================
--- trunk/libmpdemux/aac_hdr.c	Thu Feb 20 00:01:09 2014	(r36891)
+++ trunk/libmpdemux/aac_hdr.c	Thu Feb 20 00:01:10 2014	(r36892)
@@ -27,13 +27,12 @@
 /// aac_parse_frames needs a buffer at least 8 bytes long
 int aac_parse_frame(uint8_t *buf, int *srate, int *num)
 {
-	int i = 0, sr, fl = 0, id;
-	static int srates[] = {96000, 88200, 64000, 48000, 44100, 32000, 24000, 22050, 16000, 12000, 11025, 8000, 0, 0, 0};
+	int i = 0, sr, fl = 0;
+	static const int srates[] = {96000, 88200, 64000, 48000, 44100, 32000, 24000, 22050, 16000, 12000, 11025, 8000, 0, 0, 0};
 
 	if((buf[i] != 0xFF) || ((buf[i+1] & 0xF6) != 0xF0))
 		return 0;
 
-	id = (buf[i+1] >> 3) & 0x01;	//id=1 mpeg2, 0: mpeg4
 	sr = (buf[i+2] >> 2)  & 0x0F;
 	if(sr > 11)
 		return 0;


More information about the MPlayer-cvslog mailing list