[FFmpeg-cvslog] opt: Fix "libavutil/opt.c:811:20: warning: initialization discards ‘const’ quali =?UTF-8?Q?fier=20from=20pointer=20tar?==?UTF-8?Q?get=20type=20?=[ enabled by default]"

Michael Niedermayer git at videolan.org
Fri Jan 20 20:37:38 CET 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Fri Jan 20 20:27:09 2012 +0100| [2d9e2c646439514e929f39e2f5d49a26e68293d4] | committer: Michael Niedermayer

opt: Fix "libavutil/opt.c:811:20: warning: initialization discards ‘const’ qualifier from pointer target type [enabled by default]"

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

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

 libavutil/opt.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libavutil/opt.c b/libavutil/opt.c
index f0b5deb..2f8be3b 100644
--- a/libavutil/opt.c
+++ b/libavutil/opt.c
@@ -808,7 +808,7 @@ const AVClass *av_opt_child_class_next(const AVClass *parent, const AVClass *pre
 
 void *av_opt_ptr(const AVClass *class, void *obj, const char *name)
 {
-    AVOption *opt= av_opt_find2(&class, name, NULL, 0, AV_OPT_SEARCH_FAKE_OBJ, NULL);
+    const AVOption *opt= av_opt_find2(&class, name, NULL, 0, AV_OPT_SEARCH_FAKE_OBJ, NULL);
     if(!opt)
         return NULL;
     return (uint8_t*)obj + opt->offset;



More information about the ffmpeg-cvslog mailing list