asfdemux: Make a table static to avoid having to always allocate it.
authorEdward Hervey <bilboed@bilboed.com>
Sun, 14 Mar 2010 11:16:21 +0000 (12:16 +0100)
committerEdward Hervey <bilboed@bilboed.com>
Wed, 14 Apr 2010 07:30:54 +0000 (09:30 +0200)
gst/asfdemux/asfpacket.c

index 924ede8bf2b7b65d431f3030c71e55216bd4e563..2b16a3f6025128c4c07e98046d7c68f643f88703 100644 (file)
 
 /* we are unlikely to deal with lengths > 2GB here any time soon, so just
  * return a signed int and use that for error reporting */
-static gint
+static inline gint
 asf_packet_read_varlen_int (guint lentype_flags, guint lentype_bit_offset,
     const guint8 ** p_data, guint * p_size)
 {
-  const guint lens[4] = { 0, 1, 2, 4 };
+  static const guint lens[4] = { 0, 1, 2, 4 };
   guint len, val;
 
   len = lens[(lentype_flags >> lentype_bit_offset) & 0x03];