slap a bunch of shit everywhere until the crashing stops

This commit is contained in:
ouwou committed 2020-10-05 21:37:07 -04:00
1 parent cfcb0d4e66
commit 0cdaea97dd
8 files changed
+52 -18

No files matched your search

+1 -1
View File
@@ -66,7 +66,7 @@ std::string Cache::GetPathIfCached(std::string url) {
// this just seems really yucky
void Cache::CleanupFutures() {
for (auto it = m_futures.begin(); it != m_futures.end();) {
if (it->wait_for(std::chrono::seconds(0)) == std::future_status::ready)
if (it->valid() && it->wait_for(std::chrono::seconds(0)) == std::future_status::ready)
it = m_futures.erase(it);
else
it++;