summaryrefslogtreecommitdiff
path: root/libavformat/format.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-10-07 11:36:28 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-10-07 14:06:58 +0200
commitbaf89ab9a75f2c5cc1b9e9835e092278b4b978c6 (patch)
tree9412f1035d1c71cec1eba38b680d537936b00bc3 /libavformat/format.c
parent05c1f78a72916ef2466cc5a4fc778810503225ee (diff)
avformat/format: Improve const-correctness
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavformat/format.c')
-rw-r--r--libavformat/format.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/libavformat/format.c b/libavformat/format.c
index cc214741bd..387627009e 100644
--- a/libavformat/format.c
+++ b/libavformat/format.c
@@ -52,7 +52,7 @@ const AVOutputFormat *av_guess_format(const char *short_name, const char *filena
const char *mime_type)
{
const AVOutputFormat *fmt = NULL;
- AVOutputFormat *fmt_found = NULL;
+ const AVOutputFormat *fmt_found = NULL;
void *i = 0;
int score_max, score;
@@ -78,7 +78,7 @@ const AVOutputFormat *av_guess_format(const char *short_name, const char *filena
}
if (score > score_max) {
score_max = score;
- fmt_found = (AVOutputFormat*)fmt;
+ fmt_found = fmt;
}
}
return fmt_found;
@@ -121,7 +121,7 @@ const AVInputFormat *av_find_input_format(const char *short_name)
void *i = 0;
while ((fmt = av_demuxer_iterate(&i)))
if (av_match_name(short_name, fmt->name))
- return (AVInputFormat*)fmt;
+ return fmt;
return NULL;
}