Crash when saving xm files (fixes #68)

This commit is contained in:
Urs Fleisch 2012-09-30 15:42:16 +02:00 committed by Lukáš Lalinský
parent 9f597bab1b
commit 2d7414733e

View File

@ -443,7 +443,7 @@ bool XM::File::save()
return false;
uint len = std::min(22UL, instrumentHeaderSize - 4U);
if(i > lines.size())
if(i >= lines.size())
writeString(String::null, len);
else
writeString(lines[i], len);