summaryrefslogtreecommitdiff
path: root/libavformat/smoothstreamingenc.c
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2014-07-29 21:10:39 +0200
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2014-08-16 14:31:41 +0200
commita0941c8a2b3e55dc4482c874523afcb7ed6e93e6 (patch)
tree9e472048b168454605936246a7aeab4c0bade8f6 /libavformat/smoothstreamingenc.c
parentc2829dc925ffcc2a5934f3e99360a89fb0a3cad5 (diff)
downloadffmpeg-a0941c8a2b3e55dc4482c874523afcb7ed6e93e6.tar.gz
Use new av_dict_set_int helper function.
Get rid of the many, slightly differing, implementations of basically the same thing. Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Diffstat (limited to 'libavformat/smoothstreamingenc.c')
-rw-r--r--libavformat/smoothstreamingenc.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/libavformat/smoothstreamingenc.c b/libavformat/smoothstreamingenc.c
index 9491005422..0781a0a370 100644
--- a/libavformat/smoothstreamingenc.c
+++ b/libavformat/smoothstreamingenc.c
@@ -315,7 +315,6 @@ static int ism_write_header(AVFormatContext *s)
AVFormatContext *ctx;
AVStream *st;
AVDictionary *opts = NULL;
- char buf[10];
if (!s->streams[i]->codec->bit_rate) {
av_log(s, AV_LOG_ERROR, "No bit rate set for stream %d\n", i);
@@ -351,8 +350,7 @@ static int ism_write_header(AVFormatContext *s)
goto fail;
}
- snprintf(buf, sizeof(buf), "%d", c->lookahead_count);
- av_dict_set(&opts, "ism_lookahead", buf, 0);
+ av_dict_set_int(&opts, "ism_lookahead", c->lookahead_count, 0);
av_dict_set(&opts, "movflags", "frag_custom", 0);
if ((ret = avformat_write_header(ctx, &opts)) < 0) {
goto fail;