[FFmpeg-cvslog] jpeg2000: Mark static data init functions as av_cold

Diego Biurrun git at videolan.org
Tue Jun 17 21:36:47 CEST 2014


ffmpeg | branch: master | Diego Biurrun <diego at biurrun.de> | Fri Jun 13 05:38:44 2014 -0700| [fe4d5fe9361162f9033ff1bd84bfc1b2091ba785] | committer: Diego Biurrun

jpeg2000: Mark static data init functions as av_cold

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=fe4d5fe9361162f9033ff1bd84bfc1b2091ba785
---

 libavcodec/jpeg2000.c    |    3 ++-
 libavcodec/jpeg2000dec.c |    3 ++-
 libavcodec/mqc.c         |    4 +++-
 3 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/libavcodec/jpeg2000.c b/libavcodec/jpeg2000.c
index bf46398..74e4f15 100644
--- a/libavcodec/jpeg2000.c
+++ b/libavcodec/jpeg2000.c
@@ -25,6 +25,7 @@
  * JPEG 2000 image encoder and decoder common functions
  */
 
+#include "libavutil/attributes.h"
 #include "libavutil/common.h"
 #include "libavutil/mem.h"
 #include "avcodec.h"
@@ -157,7 +158,7 @@ static int getsgnctxno(int flag, uint8_t *xorbit)
     return ctxlbltab[hcontrib][vcontrib];
 }
 
-void ff_jpeg2000_init_tier1_luts(void)
+void av_cold ff_jpeg2000_init_tier1_luts(void)
 {
     int i, j;
     for (i = 0; i < 256; i++)
diff --git a/libavcodec/jpeg2000dec.c b/libavcodec/jpeg2000dec.c
index f6fa2a5..7d081ea 100644
--- a/libavcodec/jpeg2000dec.c
+++ b/libavcodec/jpeg2000dec.c
@@ -27,6 +27,7 @@
 
 #include <inttypes.h>
 
+#include "libavutil/attributes.h"
 #include "libavutil/common.h"
 #include "libavutil/opt.h"
 #include "avcodec.h"
@@ -1470,7 +1471,7 @@ end:
     return ret;
 }
 
-static void jpeg2000_init_static_data(AVCodec *codec)
+static av_cold void jpeg2000_init_static_data(AVCodec *codec)
 {
     ff_jpeg2000_init_tier1_luts();
     ff_mqc_init_context_tables();
diff --git a/libavcodec/mqc.c b/libavcodec/mqc.c
index 60d87ba..0144581 100644
--- a/libavcodec/mqc.c
+++ b/libavcodec/mqc.c
@@ -28,6 +28,8 @@
 #include <string.h>
 #include <stdint.h>
 
+#include "libavutil/attributes.h"
+
 #include "mqc.h"
 
 /* MQ coder context state structure */
@@ -92,7 +94,7 @@ uint16_t ff_mqc_qe [2 * 47];
 uint8_t ff_mqc_nlps[2 * 47];
 uint8_t ff_mqc_nmps[2 * 47];
 
-void ff_mqc_init_context_tables(void)
+void av_cold ff_mqc_init_context_tables(void)
 {
     int i;
     for (i = 0; i < 47; i++) {



More information about the ffmpeg-cvslog mailing list