You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
avformat/dashdec: use av_err2str
There is no need to explicitly specify the buffer, as it is only ever passed to av_log, so av_err2str can be used.
This commit is contained in:
@@ -277,10 +277,8 @@ static const char *get_extension_str(SegmentType type, int single_file)
|
||||
|
||||
static int handle_io_open_error(AVFormatContext *s, int err, char *url) {
|
||||
DASHContext *c = s->priv_data;
|
||||
char errbuf[AV_ERROR_MAX_STRING_SIZE];
|
||||
av_strerror(err, errbuf, sizeof(errbuf));
|
||||
av_log(s, c->ignore_io_errors ? AV_LOG_WARNING : AV_LOG_ERROR,
|
||||
"Unable to open %s for writing: %s\n", url, errbuf);
|
||||
"Unable to open %s for writing: %s\n", url, av_err2str(err));
|
||||
return c->ignore_io_errors ? 0 : err;
|
||||
}
|
||||
|
||||
@@ -1865,9 +1863,8 @@ static void dashenc_delete_file(AVFormatContext *s, char *filename) {
|
||||
} else {
|
||||
int res = ffurl_delete(filename);
|
||||
if (res < 0) {
|
||||
char errbuf[AV_ERROR_MAX_STRING_SIZE];
|
||||
av_strerror(res, errbuf, sizeof(errbuf));
|
||||
av_log(s, (res == AVERROR(ENOENT) ? AV_LOG_WARNING : AV_LOG_ERROR), "failed to delete %s: %s\n", filename, errbuf);
|
||||
av_log(s, (res == AVERROR(ENOENT) ? AV_LOG_WARNING : AV_LOG_ERROR),
|
||||
"failed to delete %s: %s\n", filename, av_err2str(res));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user