when cancelling an import, call DropReferences so that the Session forgets about the new sources.

Not doing this leaves the sources in the session list and then the session fails to open on next load
because the files are not there.

Arguably we should not announce the new files until they are complete, but this is a simpler fix for now.
This commit is contained in:
Paul Davis 2014-10-15 21:12:19 -04:00
parent 957de80389
commit 0a7a622dab

View file

@ -425,6 +425,8 @@ remove_file_source (boost::shared_ptr<Source> source)
{
boost::shared_ptr<FileSource> fs = boost::dynamic_pointer_cast<FileSource> (source);
fs->DropReferences ();
if (fs) {
::g_unlink (fs->path().c_str());
}