1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-09-23 07:29:46 +02:00

TimerRecordDialog: comment why nothing need be done for exceptions

This commit is contained in:
Paul Licameli 2017-03-15 12:14:33 -04:00
parent 63e44e2b6b
commit 1a90b7d942

View File

@ -684,9 +684,13 @@ int TimerRecordDialog::ExecutePostRecordActions(bool bWasStopped) {
break; break;
} }
// If we have simply recorded, exported and then plan to Exit/Restart/Shutdown // If we have simply recorded, exported and then plan to Exit/Restart/Shutdown
// then we will have a temporary project setup. Let's get rid of that! // then we will have a temporary project setup. Let's get rid of that!
if (m_bAutoExportEnabled && !m_bAutoSaveEnabled) { if (m_bAutoExportEnabled && !m_bAutoSaveEnabled) {
// PRL: Move the following cleanup into a finally?
// No, I think you would want to skip this, in case recording
// succeeded but then save or export threw an exception.
DirManager::CleanTempDir(); DirManager::CleanTempDir();
} }
} while (false); } while (false);
@ -694,6 +698,9 @@ int TimerRecordDialog::ExecutePostRecordActions(bool bWasStopped) {
// Do we need to cleanup the orphaned temporary project? // Do we need to cleanup the orphaned temporary project?
if (m_bProjectCleanupRequired && !bErrorOverride) { if (m_bProjectCleanupRequired && !bErrorOverride) {
// PRL: Move the following cleanup into a finally?
// No, I think you would want to skip this, in case recording
// succeeded but then save or export threw an exception.
RemoveAllAutoSaveFiles(); RemoveAllAutoSaveFiles();
} }