aac_afh.c: Make "handle" a local variable
authorAndre Noll <maan@systemlinux.org>
Sun, 4 Mar 2007 23:45:21 +0000 (00:45 +0100)
committerAndre Noll <maan@systemlinux.org>
Sun, 4 Mar 2007 23:45:21 +0000 (00:45 +0100)
Also, clean up the definition of static variables.

aac_afh.c

index e68004b24a4648f09d624e6e428ddc7d3072b27e..956ff6dad37493e5cf95990cde50204f97c226a3 100644 (file)
--- a/aac_afh.c
+++ b/aac_afh.c
 /** size of the input buffer, must be big enough to hold header */
 #define DEFAULT_INBUF_SIZE 65536
 
+static struct audio_format_handler *af;
 static FILE *infile;
-static int inbuf_size;
 static unsigned char *inbuf;
-static size_t inbuf_len;
-static struct audio_format_handler *af;
-static size_t num_chunks;
-
-static size_t *chunk_table;
-static NeAACDecHandle handle;
+static size_t inbuf_size, inbuf_len, *chunk_table, num_chunks;
 
 static void aac_close_audio_file(void)
 {
@@ -143,6 +138,7 @@ static int aac_get_file_info(FILE *file, char *info_str, long unsigned *frames,
        unsigned long rate = 0;
        unsigned char channels = 0;
        mp4AudioSpecificConfig mp4ASC;
+       NeAACDecHandle handle;
 
        inbuf_size = DEFAULT_INBUF_SIZE;
        inbuf = para_malloc(inbuf_size);