[PATCH] setupapi: do not free stack pointers (Coverity)
Marcus Meissner
marcus at jet.franken.de
Wed Jan 1 12:53:26 CST 2014
712889 Free of array-typed value
---
dlls/setupapi/query.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/setupapi/query.c b/dlls/setupapi/query.c
index e343835..f21bc36 100644
--- a/dlls/setupapi/query.c
+++ b/dlls/setupapi/query.c
@@ -607,7 +607,7 @@ BOOL WINAPI SetupGetTargetPathW( HINF hinf, PINFCONTEXT context, PCWSTR section,
else
{
SetLastError( ERROR_INSUFFICIENT_BUFFER );
- HeapFree( GetProcessHeap(), 0, dir );
+ if (dir != systemdir) HeapFree( GetProcessHeap(), 0, dir );
return FALSE;
}
}
--
1.7.10.4
More information about the wine-patches
mailing list