Commit ad6b12c6 authored by Rein Klazes's avatar Rein Klazes Committed by Alexandre Julliard

Fix a heap corruption in MIX_Init ( sizeof() != strlen() ).

parent 72d1eb47
......@@ -1445,7 +1445,7 @@ static DWORD MIX_Init(void)
mixer_info info;
if (ioctl(mixer, SOUND_MIXER_INFO, &info) >= 0) {
MIX_Mixers[i].name = HeapAlloc(GetProcessHeap(),0,strlen(info.name) + 1);
strncpy(MIX_Mixers[i].name, info.name, sizeof(info.name));
strcpy(MIX_Mixers[i].name, info.name);
} else {
/* FreeBSD up to at least 5.2 provides this ioctl, but does not
* implement it properly, and there are probably similar issues
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment