mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-04-24 17:12:34 +02:00
avformat/internal: fix compile error with some versions of g++
Fixes #6926 Signed-off-by: Aman Gupta <aman@tmm1.net>
This commit is contained in:
parent
b5958ff82e
commit
9e5e3236f4
@ -541,8 +541,11 @@ static inline int ff_rename(const char *oldpath, const char *newpath, void *logc
|
|||||||
int ret = 0;
|
int ret = 0;
|
||||||
if (rename(oldpath, newpath) == -1) {
|
if (rename(oldpath, newpath) == -1) {
|
||||||
ret = AVERROR(errno);
|
ret = AVERROR(errno);
|
||||||
if (logctx)
|
if (logctx) {
|
||||||
av_log(logctx, AV_LOG_ERROR, "failed to rename file %s to %s: %s\n", oldpath, newpath, av_err2str(ret));
|
char err[AV_ERROR_MAX_STRING_SIZE] = {0};
|
||||||
|
av_make_error_string(err, AV_ERROR_MAX_STRING_SIZE, ret);
|
||||||
|
av_log(logctx, AV_LOG_ERROR, "failed to rename file %s to %s: %s\n", oldpath, newpath, err);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user