Improved status check in garbage collection process
This commit is contained in:
parent
4e570dd9ff
commit
3164a6c502
1 changed files with 7 additions and 2 deletions
|
|
@ -683,8 +683,13 @@ void sfz::FilePool::triggerGarbageCollection() noexcept
|
|||
return status == FileData::Status::Preloaded || status == FileData::Status::FullLoaded;
|
||||
}
|
||||
|
||||
if (status != FileData::Status::Done)
|
||||
return false;
|
||||
switch (status) {
|
||||
case FileData::Status::Invalid:
|
||||
case FileData::Status::Streaming:
|
||||
return false;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if (data.readerCount != 0)
|
||||
return false;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue