Skip to content

Commit

Permalink
Merged revision(s) 22211 from trunk/OpenMPT:
Browse files Browse the repository at this point in the history
[Fix] STM: Scream Tracker 2 does not sanitize loop ends, so a sample can continue reading into the next sample's data. Fixes lessons in love.stm (https://www.un4seen.com/forum/?topic=15448.msg144130#msg144130).
........


git-svn-id: https://source.openmpt.org/svn/openmpt/branches/OpenMPT-1.30@22213 56274372-70c3-4bfc-bfc3-4c3a0b034d27
  • Loading branch information
sagamusix committed Nov 17, 2024
1 parent 4657b57 commit 865e8c1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion soundlib/Load_stm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ struct STMSampleHeader
&& mptSmp.nLoopEnd != 0xFFFF)
{
mptSmp.uFlags = CHN_LOOP;
mptSmp.nLoopEnd = std::min(mptSmp.nLoopEnd, mptSmp.nLength);
mptSmp.nLength = std::max(mptSmp.nLoopEnd, mptSmp.nLength);
}
}
};
Expand Down

0 comments on commit 865e8c1

Please sign in to comment.