correct buffer check condition
This commit is contained in:
parent
04fe0d7d04
commit
38ef6028d7
|
@ -81,7 +81,7 @@ namespace BizHawk.Emulation.Common
|
|||
/// <param name="nsamp">number of sample pairs</param>
|
||||
public unsafe void EnqueueSamples(short[] userbuf, int nsamp)
|
||||
{
|
||||
if (nsamp * 2 < userbuf.Length)
|
||||
if (userbuf.Length < nsamp * 2)
|
||||
{
|
||||
throw new("User buffer contained less than nsamp * 2 shorts!");
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue