mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-29 22:00:58 +02:00
avformat/dashenc: Enable dash output to work when the output isn't a local file
Use avpriv_io_move instead of ff_rename to support more than only the file protocol. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
20e4863ab1
commit
c66a6369e4
@ -549,7 +549,7 @@ static int write_manifest(AVFormatContext *s, int final)
|
|||||||
avio_printf(out, "</MPD>\n");
|
avio_printf(out, "</MPD>\n");
|
||||||
avio_flush(out);
|
avio_flush(out);
|
||||||
ff_format_io_close(s, &out);
|
ff_format_io_close(s, &out);
|
||||||
return ff_rename(temp_filename, s->filename, s);
|
return avpriv_io_move(temp_filename, s->filename);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int dash_write_header(AVFormatContext *s)
|
static int dash_write_header(AVFormatContext *s)
|
||||||
@ -859,7 +859,7 @@ static int dash_flush(AVFormatContext *s, int final, int stream)
|
|||||||
} else {
|
} else {
|
||||||
ffurl_close(os->out);
|
ffurl_close(os->out);
|
||||||
os->out = NULL;
|
os->out = NULL;
|
||||||
ret = ff_rename(temp_path, full_path, s);
|
ret = avpriv_io_move(temp_path, full_path);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user