mirror of
https://github.com/cookiengineer/audacity
synced 2026-02-09 13:12:17 +01:00
Flush .aup before writing .au; no redundant out-of-space messages
This commit is contained in:
@@ -313,14 +313,25 @@ XMLFileWriter::~XMLFileWriter()
|
||||
|
||||
void XMLFileWriter::Commit()
|
||||
// may throw
|
||||
{
|
||||
PreCommit();
|
||||
PostCommit();
|
||||
}
|
||||
|
||||
void XMLFileWriter::PreCommit()
|
||||
// may throw
|
||||
{
|
||||
while (mTagstack.GetCount()) {
|
||||
EndTag(mTagstack[0]);
|
||||
}
|
||||
|
||||
auto tempPath = GetName();
|
||||
CloseWithoutEndingTags();
|
||||
}
|
||||
|
||||
void XMLFileWriter::PostCommit()
|
||||
// may throw
|
||||
{
|
||||
auto tempPath = GetName();
|
||||
if (mKeepBackup) {
|
||||
if (! mBackupFile.Close() ||
|
||||
! wxRenameFile( mOutputPath, mBackupName ) )
|
||||
|
||||
Reference in New Issue
Block a user