[FFmpeg-devel] [PATCH] Warning fix: Make ogg_stream.codec const

Daniel Verkamp daniel
Wed May 6 21:24:13 CEST 2009


-------------- next part --------------
>From 12b52638950af64778c57c306c18c64e380082c2 Mon Sep 17 00:00:00 2001
From: Daniel Verkamp <daniel at drv.nu>
Date: Wed, 6 May 2009 14:25:42 -0500
Subject: [PATCH] Warning fix: Make ogg_stream.codec const

This matches the return value of ogg_find_codec and fixes
"libavformat/oggdec.c:333: warning: assignment discards qualifiers from
pointer target type"
---
 libavformat/oggdec.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libavformat/oggdec.h b/libavformat/oggdec.h
index 1d65ba7..cbba414 100644
--- a/libavformat/oggdec.h
+++ b/libavformat/oggdec.h
@@ -53,7 +53,7 @@ struct ogg_stream {
     uint32_t seq;
     uint64_t granule, lastgp;
     int flags;
-    struct ogg_codec *codec;
+    const struct ogg_codec *codec;
     int header;
     int nsegs, segp;
     uint8_t segments[255];
-- 
1.6.2.3



More information about the ffmpeg-devel mailing list