mirror of
https://github.com/reactos/reactos.git
synced 2025-02-22 16:36:33 +00:00
[MMIXER] Fix overzealous asserts. CORE-16611
MAXPNAMELEN is the size of the array, so if wcslen returns MAXPNAMELEN-1, the null terminator fits and everything is okay.
This commit is contained in:
parent
355700f45a
commit
2bbc94c6ac
2 changed files with 2 additions and 2 deletions
|
@ -72,7 +72,7 @@ MMixerAddMidiPin(
|
|||
MidiInfo->PinId = PinId;
|
||||
|
||||
/* sanity check */
|
||||
ASSERT(!DeviceName || (wcslen(DeviceName) + 1 < MAXPNAMELEN));
|
||||
ASSERT(!DeviceName || (wcslen(DeviceName) < MAXPNAMELEN));
|
||||
|
||||
/* copy device name */
|
||||
if (bInput && DeviceName)
|
||||
|
|
|
@ -357,7 +357,7 @@ MMixerInitializeWaveInfo(
|
|||
WaveInfo->PinId = Pins[0];
|
||||
|
||||
/* sanity check */
|
||||
ASSERT(wcslen(DeviceName) + 1 < MAXPNAMELEN);
|
||||
ASSERT(wcslen(DeviceName) < MAXPNAMELEN);
|
||||
|
||||
/* copy device name */
|
||||
if (bWaveIn)
|
||||
|
|
Loading…
Reference in a new issue