[FFmpeg-cvslog] lavf: mark stream as const pointer in av_stream_get_side_data() for next bump

Clément Bœsch git at videolan.org
Wed Aug 17 17:34:24 EEST 2016


ffmpeg | branch: master | Clément Bœsch <clement at stupeflix.com> | Mon Jun 27 11:28:12 2016 +0200| [ffd71c9c5c64c82923c38406411a3da9a16aa150] | committer: Clément Bœsch

lavf: mark stream as const pointer in av_stream_get_side_data() for next bump

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

 libavformat/avformat.h | 5 +++++
 libavformat/utils.c    | 9 +++++++--
 libavformat/version.h  | 7 +++++--
 3 files changed, 17 insertions(+), 4 deletions(-)

diff --git a/libavformat/avformat.h b/libavformat/avformat.h
index d8a6cf3..3ee7051 100644
--- a/libavformat/avformat.h
+++ b/libavformat/avformat.h
@@ -2053,8 +2053,13 @@ uint8_t *av_stream_new_side_data(AVStream *stream,
  * @param size pointer for side information size to store (optional)
  * @return pointer to data if present or NULL otherwise
  */
+#if FF_API_NOCONST_GET_SIDE_DATA
 uint8_t *av_stream_get_side_data(AVStream *stream,
                                  enum AVPacketSideDataType type, int *size);
+#else
+uint8_t *av_stream_get_side_data(const AVStream *stream,
+                                 enum AVPacketSideDataType type, int *size);
+#endif
 
 AVProgram *av_new_program(AVFormatContext *s, int id);
 
diff --git a/libavformat/utils.c b/libavformat/utils.c
index 8156a80..c84d69c 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -5007,8 +5007,13 @@ int ff_generate_avci_extradata(AVStream *st)
     return 0;
 }
 
-uint8_t *av_stream_get_side_data(AVStream *st, enum AVPacketSideDataType type,
-                                 int *size)
+#if FF_API_NOCONST_GET_SIDE_DATA
+uint8_t *av_stream_get_side_data(AVStream *st,
+                                 enum AVPacketSideDataType type, int *size)
+#else
+uint8_t *av_stream_get_side_data(const AVStream *st,
+                                 enum AVPacketSideDataType type, int *size)
+#endif
 {
     int i;
 
diff --git a/libavformat/version.h b/libavformat/version.h
index 6f47a2f..a67d118 100644
--- a/libavformat/version.h
+++ b/libavformat/version.h
@@ -32,8 +32,8 @@
 // Major bumping may affect Ticket5467, 5421, 5451(compatibility with Chromium)
 // Also please add any ticket numbers that you belive might be affected here
 #define LIBAVFORMAT_VERSION_MAJOR  57
-#define LIBAVFORMAT_VERSION_MINOR  46
-#define LIBAVFORMAT_VERSION_MICRO 101
+#define LIBAVFORMAT_VERSION_MINOR  47
+#define LIBAVFORMAT_VERSION_MICRO 100
 
 #define LIBAVFORMAT_VERSION_INT AV_VERSION_INT(LIBAVFORMAT_VERSION_MAJOR, \
                                                LIBAVFORMAT_VERSION_MINOR, \
@@ -79,6 +79,9 @@
 #ifndef FF_API_LAVF_AVCTX
 #define FF_API_LAVF_AVCTX               (LIBAVFORMAT_VERSION_MAJOR < 58)
 #endif
+#ifndef FF_API_NOCONST_GET_SIDE_DATA
+#define FF_API_NOCONST_GET_SIDE_DATA    (LIBAVFORMAT_VERSION_MAJOR < 58)
+#endif
 
 #ifndef FF_API_R_FRAME_RATE
 #define FF_API_R_FRAME_RATE            1



More information about the ffmpeg-cvslog mailing list