Hans Leidekker : setupapi: Correctly handle an empty filename in SetupGetSourceFileLocationA.

Alexandre Julliard julliard at wine.codeweavers.com
Fri May 18 08:03:56 CDT 2007


Module: wine
Branch: master
Commit: 108288ec3af19a10e152a18bd60240ad17430b69
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=108288ec3af19a10e152a18bd60240ad17430b69

Author: Hans Leidekker <hans at it.vu.nl>
Date:   Fri May 18 11:38:53 2007 +0200

setupapi: Correctly handle an empty filename in SetupGetSourceFileLocationA.

---

 dlls/setupapi/query.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dlls/setupapi/query.c b/dlls/setupapi/query.c
index 8699264..3a74717 100644
--- a/dlls/setupapi/query.c
+++ b/dlls/setupapi/query.c
@@ -320,7 +320,7 @@ BOOL WINAPI SetupGetSourceFileLocationA( HINF hinf, PINFCONTEXT context, PCSTR f
     TRACE("%p, %p, %s, %p, %p, 0x%08x, %p\n", hinf, context, debugstr_a(filename), source_id,
           buffer, buffer_size, required_size);
 
-    if (filename && !(filenameW = strdupAtoW( filename )))
+    if (filename && *filename && !(filenameW = strdupAtoW( filename )))
         return FALSE;
 
     if (!SetupGetSourceFileLocationW( hinf, context, filenameW, source_id, NULL, 0, &required ))




More information about the wine-cvs mailing list