1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-11-05 16:43:52 +01:00

Graceful failure saving to thumb drive... (#649)

... If renaming of the file (to a place on a different device) fails,
recover correctly before giving the warning message
This commit is contained in:
Paul Licameli
2020-08-28 12:19:37 -04:00
committed by GitHub
parent 22c00fab03
commit 29f3361746

View File

@@ -1903,6 +1903,12 @@ bool ProjectFileIO::SaveProject(const FilePath &fileName, const std::shared_ptr<
OpenConnection(savedName);
}
}
else {
// Rename can fail -- if it's to a different device, requiring
// real copy of contents, which might exhaust space
OpenConnection(savedName);
return false;
}
}
}