On Mon, Jan 4, 2016 at 8:36 AM, Hendrik Leppkes <h.lepp...@gmail.com> wrote: > On Mon, Jan 4, 2016 at 3:58 PM, <r...@vizrt.com> wrote: >> From: Raymond Hilseth <r...@vizrt.com> >> >> Signed-off-by: Raymond Hilseth <r...@vizrt.com> >> --- >> libavformat/dashenc.c | 4 ++-- >> 1 file changed, 2 insertions(+), 2 deletions(-) >> >> diff --git a/libavformat/dashenc.c b/libavformat/dashenc.c >> index 4509ee4..378c4e4 100644 >> --- a/libavformat/dashenc.c >> +++ b/libavformat/dashenc.c >> @@ -549,7 +549,7 @@ static int write_manifest(AVFormatContext *s, int final) >> avio_printf(out, "</MPD>\n"); >> avio_flush(out); >> avio_close(out); >> - return ff_rename(temp_filename, s->filename, s); >> + return avpriv_io_move(temp_filename, s->filename); >> } >> >> static int dash_write_header(AVFormatContext *s) >> @@ -856,7 +856,7 @@ static int dash_flush(AVFormatContext *s, int final, int >> stream) >> } else { >> ffurl_close(os->out); >> os->out = NULL; >> - ret = ff_rename(temp_path, full_path, s); >> + ret = avpriv_io_move(temp_path, full_path); >> if (ret < 0) >> break; >> } >> -- > > For unknown reasons, url_move(which avpriv_io_move uses) in the "file" > protocol depends on unistd.h, which is not available everywhere.
Yes, this is strange. url_move points to file_move, and the only system functionality it relies on is rename, available in stdio.h. The semantics vary from system to system, with some details specified in POSIX, but rename itself is standard C: http://en.cppreference.com/w/c/io/rename. As the code is recent, dating to this year's gsoc, 824a82d1b8, it may not be too surprising that this was not addressed yet. > So commiting this without making sure file.url_move is available on > all systems where ff_rename works would introduce a regression. > > - Hendrik > _______________________________________________ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > http://ffmpeg.org/mailman/listinfo/ffmpeg-devel _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel