diff options
author | Marton Balint <cus@passwd.hu> | 2017-12-29 23:29:27 +0100 |
---|---|---|
committer | Marton Balint <cus@passwd.hu> | 2018-01-28 23:06:43 +0100 |
commit | 25a2d269bdd919e633e202b67927c3c72f9f0dd5 (patch) | |
tree | b704890db0eef099f1e8203cfe056e3567b00063 /doc/examples/transcode_aac.c | |
parent | ea3672b7d67c432724bdbc8de0221f869b6a04c6 (diff) |
fftools, tools, examples: migrate to AVFormatContext->url
Signed-off-by: Marton Balint <cus@passwd.hu>
Diffstat (limited to 'doc/examples/transcode_aac.c')
-rw-r--r-- | doc/examples/transcode_aac.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/doc/examples/transcode_aac.c b/doc/examples/transcode_aac.c index 9fd5c00d60..3c7688cd33 100644 --- a/doc/examples/transcode_aac.c +++ b/doc/examples/transcode_aac.c @@ -171,8 +171,11 @@ static int open_output_file(const char *filename, goto cleanup; } - av_strlcpy((*output_format_context)->filename, filename, - sizeof((*output_format_context)->filename)); + if (!((*output_format_context)->url = av_strdup(filename))) { + fprintf(stderr, "Could not allocate url.\n"); + error = AVERROR(ENOMEM); + goto cleanup; + } /* Find the encoder to be used by its name. */ if (!(output_codec = avcodec_find_encoder(AV_CODEC_ID_AAC))) { |