Bug2603: Should give proper message for failed backup onto FAT drive...

... The error message eliminated here describes what should be ruled out by
the loop before this line, which already checks that no previous file of the
chosen name exists.

So just give the generic write failure message.
This commit is contained in:
Paul Licameli 2020-12-09 18:00:41 -05:00
parent bc7066a20e
commit 4cb9bb19fd
1 changed files with 3 additions and 6 deletions

View File

@ -589,14 +589,11 @@ bool ProjectFileManager::SaveCopy(const FilePath &fileName /* = wxT("") */)
break;
} while (bPrompt);
if (!projectFileIO.SaveCopy(filename.GetFullPath()))
if (!projectFileIO.SaveCopy(fName))
{
// Overwrite disallowed. The destination project is open in another window.
auto msg = FileException::WriteFailureMessage(fName);
AudacityMessageDialog m(
nullptr,
XO("The project will not be saved because the selected project is open in another window.\nPlease try again and select an original name."),
XO("Error Saving Project"),
wxOK | wxICON_ERROR);
nullptr, msg, XO("Error Saving Project"), wxOK | wxICON_ERROR);
m.ShowModal();