summaryrefslogtreecommitdiff
path: root/libavformat
diff options
context:
space:
mode:
authorClément Bœsch <ubitux@gmail.com>2011-05-29 21:07:34 +0200
committerMichael Niedermayer <michaelni@gmx.at>2011-05-30 00:24:01 +0200
commitadba9c63525b8971fc6ccda47e643dca05c3ee9d (patch)
tree7f4521c4ceaf684a4cdc4f8b57db30a4364c35e0 /libavformat
parentfd38a15adf7f4e20f25d89f162e4a8fbbd8ec92e (diff)
Fix various unused variable warnings
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/4xm.c2
-rw-r--r--libavformat/apetag.c2
-rw-r--r--libavformat/asfdec.c10
-rw-r--r--libavformat/mmf.c4
-rw-r--r--libavformat/mov.c6
-rw-r--r--libavformat/oggdec.c4
-rw-r--r--libavformat/oggparsecelt.c4
-rw-r--r--libavformat/oggparseogm.c2
-rw-r--r--libavformat/rl2.c4
-rw-r--r--libavformat/rmdec.c2
-rw-r--r--libavformat/rpl.c2
-rw-r--r--libavformat/rtpdec_latm.c2
-rw-r--r--libavformat/sauce.c2
-rw-r--r--libavformat/smacker.c2
-rw-r--r--libavformat/sol.c2
-rw-r--r--libavformat/yuv4mpeg.c4
16 files changed, 25 insertions, 29 deletions
diff --git a/libavformat/4xm.c b/libavformat/4xm.c
index 699277248d..42ecbde581 100644
--- a/libavformat/4xm.c
+++ b/libavformat/4xm.c
@@ -246,7 +246,7 @@ static int fourxm_read_packet(AVFormatContext *s,
FourxmDemuxContext *fourxm = s->priv_data;
AVIOContext *pb = s->pb;
unsigned int fourcc_tag;
- unsigned int size, out_size;
+ unsigned int size, out_size av_unused;
int ret = 0;
unsigned int track_number;
int packet_read = 0;
diff --git a/libavformat/apetag.c b/libavformat/apetag.c
index fb46d2bac2..4a464de1f5 100644
--- a/libavformat/apetag.c
+++ b/libavformat/apetag.c
@@ -35,7 +35,7 @@ static int ape_tag_read_field(AVFormatContext *s)
{
AVIOContext *pb = s->pb;
uint8_t key[1024], *value;
- uint32_t size, flags;
+ uint32_t size, flags av_unused;
int i, c;
size = avio_rl32(pb); /* field size */
diff --git a/libavformat/asfdec.c b/libavformat/asfdec.c
index 3564bf465f..e2efeef3ea 100644
--- a/libavformat/asfdec.c
+++ b/libavformat/asfdec.c
@@ -209,7 +209,7 @@ static int asf_read_stream_properties(AVFormatContext *s, int64_t size)
ff_asf_guid g;
enum AVMediaType type;
int type_specific_size, sizeX;
- uint64_t total_size;
+ uint64_t total_size av_unused;
unsigned int tag1;
int64_t pos1, pos2, start_time;
int test_for_ext_stream_audio, is_dvr_ms_audio=0;
@@ -393,7 +393,7 @@ static int asf_read_ext_stream_properties(AVFormatContext *s, int64_t size)
AVIOContext *pb = s->pb;
ff_asf_guid g;
int ext_len, payload_ext_ct, stream_ct, i;
- uint32_t ext_d, leak_rate, stream_num;
+ uint32_t ext_d av_unused, leak_rate, stream_num;
unsigned int stream_languageid_index;
avio_rl64(pb); // starttime
@@ -511,7 +511,7 @@ static int asf_read_metadata(AVFormatContext *s, int64_t size)
{
AVIOContext *pb = s->pb;
ASFContext *asf = s->priv_data;
- int n, stream_num, name_len, value_len, value_type, value_num;
+ int n, stream_num, name_len, value_len, value_type av_unused, value_num;
int ret, i;
n = avio_rl16(pb);
@@ -626,7 +626,7 @@ static int asf_read_header(AVFormatContext *s, AVFormatParameters *ap)
// if so the next iteration will pick it up
continue;
} else if (!ff_guidcmp(&g, &ff_asf_head1_guid)) {
- int v1, v2;
+ av_unused int v1, v2;
ff_get_guid(pb, &g);
v1 = avio_rl32(pb);
v2 = avio_rl16(pb);
@@ -799,7 +799,7 @@ static int asf_read_frame_header(AVFormatContext *s, AVIOContext *pb){
ASFContext *asf = s->priv_data;
int rsize = 1;
int num = avio_r8(pb);
- int64_t ts0, ts1;
+ int64_t ts0, ts1 av_unused;
asf->packet_segments--;
asf->packet_key_frame = num >> 7;
diff --git a/libavformat/mmf.c b/libavformat/mmf.c
index fc6fcc3caa..b75bee3a6b 100644
--- a/libavformat/mmf.c
+++ b/libavformat/mmf.c
@@ -186,7 +186,7 @@ static int mmf_read_header(AVFormatContext *s,
unsigned int tag;
AVIOContext *pb = s->pb;
AVStream *st;
- int64_t file_size, size;
+ int64_t file_size av_unused, size;
int rate, params;
tag = avio_rl32(pb);
@@ -263,12 +263,10 @@ static int mmf_read_packet(AVFormatContext *s,
AVPacket *pkt)
{
MMFContext *mmf = s->priv_data;
- AVStream *st;
int ret, size;
if (url_feof(s->pb))
return AVERROR(EIO);
- st = s->streams[0];
size = MAX_SIZE;
if(size > mmf->data_size)
diff --git a/libavformat/mov.c b/libavformat/mov.c
index e51116b304..1af1cdeb63 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -469,21 +469,21 @@ static int mov_read_hdlr(MOVContext *c, AVIOContext *pb, MOVAtom atom)
int ff_mov_read_esds(AVFormatContext *fc, AVIOContext *pb, MOVAtom atom)
{
AVStream *st;
- int tag, len;
+ int tag;
if (fc->nb_streams < 1)
return 0;
st = fc->streams[fc->nb_streams-1];
avio_rb32(pb); /* version + flags */
- len = ff_mp4_read_descr(fc, pb, &tag);
+ ff_mp4_read_descr(fc, pb, &tag);
if (tag == MP4ESDescrTag) {
avio_rb16(pb); /* ID */
avio_r8(pb); /* priority */
} else
avio_rb16(pb); /* ID */
- len = ff_mp4_read_descr(fc, pb, &tag);
+ ff_mp4_read_descr(fc, pb, &tag);
if (tag == MP4DecConfigDescrTag)
ff_mp4_read_dec_config_descr(fc, st, pb);
return 0;
diff --git a/libavformat/oggdec.c b/libavformat/oggdec.c
index 344bd1ccd8..968cdd90e3 100644
--- a/libavformat/oggdec.c
+++ b/libavformat/oggdec.c
@@ -197,8 +197,8 @@ static int ogg_read_page(AVFormatContext *s, int *str)
int flags, nsegs;
uint64_t gp;
uint32_t serial;
- uint32_t seq;
- uint32_t crc;
+ uint32_t seq av_unused;
+ uint32_t crc av_unused;
int size, idx;
uint8_t sync[4];
int sp = 0;
diff --git a/libavformat/oggparsecelt.c b/libavformat/oggparsecelt.c
index bbb695f438..2adc06046a 100644
--- a/libavformat/oggparsecelt.c
+++ b/libavformat/oggparsecelt.c
@@ -41,8 +41,8 @@ static int celt_header(AVFormatContext *s, int idx)
/* Main header */
- uint32_t version, header_size, sample_rate, nb_channels, frame_size;
- uint32_t overlap, bytes_per_packet, extra_headers;
+ uint32_t version, header_size av_unused, sample_rate, nb_channels, frame_size;
+ uint32_t overlap, bytes_per_packet av_unused, extra_headers;
uint8_t *extradata;
extradata = av_malloc(2 * sizeof(uint32_t) +
diff --git a/libavformat/oggparseogm.c b/libavformat/oggparseogm.c
index dda5be601a..ec575e068d 100644
--- a/libavformat/oggparseogm.c
+++ b/libavformat/oggparseogm.c
@@ -39,7 +39,7 @@ ogm_header(AVFormatContext *s, int idx)
const uint8_t *p = os->buf + os->pstart;
uint64_t time_unit;
uint64_t spu;
- uint32_t default_len;
+ uint32_t default_len av_unused;
if(!(*p & 1))
return 0;
diff --git a/libavformat/rl2.c b/libavformat/rl2.c
index 93d4c34459..219aa697b6 100644
--- a/libavformat/rl2.c
+++ b/libavformat/rl2.c
@@ -80,8 +80,8 @@ static av_cold int rl2_read_header(AVFormatContext *s,
unsigned int audio_frame_counter = 0;
unsigned int video_frame_counter = 0;
unsigned int back_size;
- int data_size;
- unsigned short encoding_method;
+ int data_size av_unused;
+ unsigned short encoding_method av_unused;
unsigned short sound_rate;
unsigned short rate;
unsigned short channels;
diff --git a/libavformat/rmdec.c b/libavformat/rmdec.c
index 6fb362473e..5c24d021e0 100644
--- a/libavformat/rmdec.c
+++ b/libavformat/rmdec.c
@@ -280,7 +280,7 @@ ff_rm_read_mdpr_codecdata (AVFormatContext *s, AVIOContext *pb,
if (rm_read_audio_stream_info(s, pb, st, rst, 0))
return -1;
} else {
- int fps, fps2;
+ int fps, fps2 av_unused;
if (avio_rl32(pb) != MKTAG('V', 'I', 'D', 'O')) {
fail1:
av_log(st->codec, AV_LOG_ERROR, "Unsupported video codec\n");
diff --git a/libavformat/rpl.c b/libavformat/rpl.c
index 9702fc7035..be5bf9c788 100644
--- a/libavformat/rpl.c
+++ b/libavformat/rpl.c
@@ -299,7 +299,7 @@ static int rpl_read_packet(AVFormatContext *s, AVPacket *pkt)
stream->codec->codec_tag == 124) {
// We have to split Escape 124 frames because there are
// multiple frames per chunk in Escape 124 samples.
- uint32_t frame_size, frame_flags;
+ uint32_t frame_size, frame_flags av_unused;
frame_flags = avio_rl32(pb);
frame_size = avio_rl32(pb);
diff --git a/libavformat/rtpdec_latm.c b/libavformat/rtpdec_latm.c
index 2b366a0dc2..74754dfd60 100644
--- a/libavformat/rtpdec_latm.c
+++ b/libavformat/rtpdec_latm.c
@@ -108,7 +108,7 @@ static int parse_fmtp_config(AVStream *st, char *value)
int len = ff_hex_to_data(NULL, value), i, ret = 0;
GetBitContext gb;
uint8_t *config;
- int audio_mux_version, same_time_framing, num_sub_frames,
+ int audio_mux_version, same_time_framing, num_sub_frames av_unused,
num_programs, num_layers;
/* Pad this buffer, too, to avoid out of bounds reads with get_bits below */
diff --git a/libavformat/sauce.c b/libavformat/sauce.c
index 41e991e3e7..0b22a75bb9 100644
--- a/libavformat/sauce.c
+++ b/libavformat/sauce.c
@@ -32,7 +32,7 @@ int ff_sauce_read(AVFormatContext *avctx, uint64_t *fsize, int *got_width, int g
{
AVIOContext *pb = avctx->pb;
char buf[36];
- int datatype, filetype, t1, t2, nb_comments, flags;
+ int datatype, filetype, t1, t2, nb_comments, flags av_unused;
uint64_t start_pos = avio_size(pb) - 128;
avio_seek(pb, start_pos, SEEK_SET);
diff --git a/libavformat/smacker.c b/libavformat/smacker.c
index 2603a4d71c..29a66e79fa 100644
--- a/libavformat/smacker.c
+++ b/libavformat/smacker.c
@@ -233,7 +233,6 @@ static int smacker_read_packet(AVFormatContext *s, AVPacket *pkt)
int i;
int frame_size = 0;
int palchange = 0;
- int pos;
if (url_feof(s->pb) || smk->cur_frame >= smk->frames)
return AVERROR_EOF;
@@ -244,7 +243,6 @@ static int smacker_read_packet(AVFormatContext *s, AVPacket *pkt)
frame_size = smk->frm_size[smk->cur_frame] & (~3);
flags = smk->frm_flags[smk->cur_frame];
/* handle palette change event */
- pos = avio_tell(s->pb);
if(flags & SMACKER_PAL){
int size, sz, t, off, j, pos;
uint8_t *pal = smk->pal;
diff --git a/libavformat/sol.c b/libavformat/sol.c
index 7ad894e304..70fddae92a 100644
--- a/libavformat/sol.c
+++ b/libavformat/sol.c
@@ -85,7 +85,7 @@ static int sol_channels(int magic, int type)
static int sol_read_header(AVFormatContext *s,
AVFormatParameters *ap)
{
- int size;
+ int size av_unused;
unsigned int magic,tag;
AVIOContext *pb = s->pb;
unsigned int id, channels, rate, type;
diff --git a/libavformat/yuv4mpeg.c b/libavformat/yuv4mpeg.c
index a852568a64..445ec3701b 100644
--- a/libavformat/yuv4mpeg.c
+++ b/libavformat/yuv4mpeg.c
@@ -94,7 +94,7 @@ static int yuv4_write_packet(AVFormatContext *s, AVPacket *pkt)
AVPicture *picture;
int* first_pkt = s->priv_data;
int width, height, h_chroma_shift, v_chroma_shift;
- int i, m;
+ int i;
char buf2[Y4M_LINE_MAX+1];
char buf1[20];
uint8_t *ptr, *ptr1, *ptr2;
@@ -114,7 +114,7 @@ static int yuv4_write_packet(AVFormatContext *s, AVPacket *pkt)
/* construct frame header */
- m = snprintf(buf1, sizeof(buf1), "%s\n", Y4M_FRAME_MAGIC);
+ snprintf(buf1, sizeof(buf1), "%s\n", Y4M_FRAME_MAGIC);
avio_write(pb, buf1, strlen(buf1));
width = st->codec->width;