Author: hpoussin
Date: Mon Jul 24 16:14:26 2006
New Revision: 23264
URL:
http://svn.reactos.org/svn/reactos?rev=23264&view=rev
Log:
Don't try to free twice a pointer.
Modified:
trunk/reactos/dll/win32/setupapi/driver.c
Modified: trunk/reactos/dll/win32/setupapi/driver.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/setupapi/driver.…
==============================================================================
--- trunk/reactos/dll/win32/setupapi/driver.c (original)
+++ trunk/reactos/dll/win32/setupapi/driver.c Mon Jul 24 16:14:26 2006
@@ -307,7 +307,7 @@
&RequiredSize);
if (Result)
{
- /* We know know the needed buffer size */
+ /* We know the needed buffer size */
ProviderName = HeapAlloc(GetProcessHeap(), 0, RequiredSize * sizeof(WCHAR));
if (!ProviderName)
{
@@ -405,7 +405,10 @@
cleanup:
if (!ret)
+ {
HeapFree(GetProcessHeap(), 0, ProviderName);
+ *pProviderName = NULL;
+ }
HeapFree(GetProcessHeap(), 0, DriverVer);
return ret;