You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-04 22:03:09 +02:00
tools/sidxindex: use av_err2str
There is no need to explicitly specify the buffer, as it is only ever passed to fprintf, so av_err2str can be used.
This commit is contained in:
@ -119,20 +119,18 @@ static int handle_file(struct Tracks *tracks, const char *file)
|
||||
{
|
||||
AVFormatContext *ctx = NULL;
|
||||
int err = 0, i, orig_tracks = tracks->nb_tracks;
|
||||
char errbuf[50], *ptr;
|
||||
char *ptr;
|
||||
struct Track *track;
|
||||
|
||||
err = avformat_open_input(&ctx, file, NULL, NULL);
|
||||
if (err < 0) {
|
||||
av_strerror(err, errbuf, sizeof(errbuf));
|
||||
fprintf(stderr, "Unable to open %s: %s\n", file, errbuf);
|
||||
fprintf(stderr, "Unable to open %s: %s\n", file, av_err2str(err));
|
||||
return 1;
|
||||
}
|
||||
|
||||
err = avformat_find_stream_info(ctx, NULL);
|
||||
if (err < 0) {
|
||||
av_strerror(err, errbuf, sizeof(errbuf));
|
||||
fprintf(stderr, "Unable to identify %s: %s\n", file, errbuf);
|
||||
fprintf(stderr, "Unable to identify %s: %s\n", file, av_err2str(err));
|
||||
goto fail;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user