[resend] wineboot: fix installation of SFP protected files

Alexandre Julliard julliard at winehq.org
Thu Jan 10 05:19:32 CST 2008


Andrey Turkin <andrey.turkin at gmail.com> writes:

> @@ -494,7 +494,11 @@ static int ProcessWindowsFileProtection(void)
>          strcatW( dllcache, dllcacheW );
>      }
>  
> -    find_handle = FindFirstFileW(dllcache,&finddata);
> +    dllcache_wildcard = HeapAlloc(GetProcessHeap(), 0, strlenW( dllcache )*sizeof(WCHAR) + sizeof(wildcardW));
> +    strcpyW(dllcache_wildcard,dllcache);
> +    strcatW(dllcache_wildcard,wildcardW);
> +
> +    find_handle = FindFirstFileW( dllcache_wildcard, &finddata );

You could simply remove the wildcard from the end of string after
FindFirstFile, no need to copy the whole string.

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-devel mailing list