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:
@@ -1903,6 +1903,12 @@ bool ProjectFileIO::SaveProject(const FilePath &fileName, const std::shared_ptr<
|
|||||||
OpenConnection(savedName);
|
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;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user