Author: jgardou
Date: Mon Oct 17 16:35:10 2011
New Revision: 54179
URL:
http://svn.reactos.org/svn/reactos?rev=54179&view=rev
Log:
[WinMM]
- avoid buffer overrun.
- do not try to unload uninitialized driver.
See issue #6343 for more details.
Modified:
trunk/reactos/dll/win32/winmm/lolvldrv.c
Modified: trunk/reactos/dll/win32/winmm/lolvldrv.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/winmm/lolvldrv.c…
==============================================================================
--- trunk/reactos/dll/win32/winmm/lolvldrv.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/winmm/lolvldrv.c [iso-8859-1] Mon Oct 17 16:35:10 2011
@@ -634,7 +634,7 @@
}
/* unload driver, in reverse order of loading */
- i = sizeof(MMDrvs) / sizeof(MMDrvs[0]);
+ i = MMDrvsHi - 1;
while (i-- > 0)
{
MMDRV_ExitPerType(&MMDrvs[i], MMDRV_AUX);