[PATCH][kernel32.dll] quick and dirty implementation of GetVolumePathNamesForVolumeNameA (try 2)

James Mckenzie jjmckenzie51 at earthlink.net
Thu Jul 1 14:17:54 CDT 2010


Tuomo Mattila <tuomom at ee.oulu.fi> wrote:

Why not just do the check and then pass it as a Wide to the 'W' function?  

Simpler and less code to maintain/update?


>+
>+
>+    FIXME("(%s, %p, %d, %p), stub!\n", debugstr_a(volumename), volumepathname, buflen, returnlen);

If this is not a full implementation, you need to state so, otherwise this goes....

>+
>+    if (volumename == 0 || volumepathname == 0 || returnlen == 0)
>+    {
>+        SetLastError(RPC_X_NULL_REF_POINTER);
>+        return FALSE;
>+    }

At this point you should convert to Wide/UNICODE and pass to the W function.  Pass the return from the W call back to the caller.

>+
>+    return TRUE;
>+}
>+
>+/***********************************************************************
>  *           GetVolumePathNamesForVolumeNameW   (KERNEL32.@)
>  */
> BOOL WINAPI GetVolumePathNamesForVolumeNameW(LPCWSTR volumename, LPWSTR volumepathname, DWORD buflen, PDWORD returnlen)
>-- 
>1.7.1
>
>
>




More information about the wine-devel mailing list