error handling

This commit is contained in:
Glenn Maynard
2005-12-06 17:45:35 +00:00
parent 343c4d106c
commit 533e2e2175
+5 -1
View File
@@ -295,7 +295,11 @@ bool NotesWriterSM::WriteEditFileToMachine( const Song *pSong, Steps *pSteps )
CString sTag;
GetEditFileContents( pSong, pSteps, sTag );
f.PutLine( sTag );
if( f.PutLine(sTag) == -1 || f.Flush() == -1 )
{
LOG->Warn( "Error writing song file '%s': %s", sPath.c_str(), f.GetError().c_str() );
return false;
}
return true;
}