check if tags are properly saved

This commit is contained in:
Andrzej Rybczak
2009-01-22 12:41:45 +01:00
parent 49724329f1
commit 962f80ea83

View File

@@ -397,7 +397,8 @@ bool WriteTags(Song &s)
f.tag()->setTrack(StrToInt(s.GetTrack()));
f.tag()->setGenre(ToWString(s.GetGenre()));
f.tag()->setComment(ToWString(s.GetComment()));
f.save();
if (!f.save())
return false;
string ext = s.GetFile();
ext = ext.substr(ext.find_last_of(".")+1);
@@ -422,7 +423,8 @@ bool WriteTags(Song &s)
tag->addFrame(PerformerFrame);
tag->removeFrames(Disc);
tag->addFrame(DiscFrame);
file.save();
if (!file.save())
return false;
}
if (!s.GetNewName().empty())
{