forked from premiere/premiere-libtorrent
flush and close the partfile when releasing files in default storage
This commit is contained in:
parent
9399033588
commit
e31433d952
|
@ -562,6 +562,13 @@ namespace libtorrent
|
||||||
|
|
||||||
void default_storage::release_files(storage_error&)
|
void default_storage::release_files(storage_error&)
|
||||||
{
|
{
|
||||||
|
if (m_part_file)
|
||||||
|
{
|
||||||
|
error_code ignore;
|
||||||
|
m_part_file->flush_metadata(ignore);
|
||||||
|
m_part_file.reset();
|
||||||
|
}
|
||||||
|
|
||||||
// make sure we don't have the files open
|
// make sure we don't have the files open
|
||||||
m_pool.release(this);
|
m_pool.release(this);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue