summaryrefslogtreecommitdiff
path: root/libavformat/ffmenc.c
diff options
context:
space:
mode:
authorMarton Balint <cus@passwd.hu>2016-02-06 17:58:01 +0100
committerMarton Balint <cus@passwd.hu>2016-02-14 01:51:14 +0100
commit83b01ed21239e88dba09b05cde5c2cd5b65f20e0 (patch)
treef275c64b829813998a20dc6988be7856500cd503 /libavformat/ffmenc.c
parentbf0607b6dbca9e9faebe8b038f45353dd6c0659c (diff)
downloadffmpeg-83b01ed21239e88dba09b05cde5c2cd5b65f20e0.tar.gz
avformat/ffmenc: use ff_parse_creation_time_metadata
FYI this muxer bails out on parse error and not just warn the user. Signed-off-by: Marton Balint <cus@passwd.hu>
Diffstat (limited to 'libavformat/ffmenc.c')
-rw-r--r--libavformat/ffmenc.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/libavformat/ffmenc.c b/libavformat/ffmenc.c
index f0b5743ea4..0f23b796a0 100644
--- a/libavformat/ffmenc.c
+++ b/libavformat/ffmenc.c
@@ -221,17 +221,13 @@ static int ffm_write_recommended_config(AVIOContext *pb, AVCodecContext *ctx, un
static int ffm_write_header(AVFormatContext *s)
{
FFMContext *ffm = s->priv_data;
- AVDictionaryEntry *t;
AVStream *st;
AVIOContext *pb = s->pb;
AVCodecContext *codec;
int bit_rate, i, ret;
- if (t = av_dict_get(s->metadata, "creation_time", NULL, 0)) {
- ret = av_parse_time(&ffm->start_time, t->value, 0);
- if (ret < 0)
- return ret;
- }
+ if ((ret = ff_parse_creation_time_metadata(s, &ffm->start_time, 0)) < 0)
+ return ret;
ffm->packet_size = FFM_PACKET_SIZE;