patch for "GetFileTitleW: illegal call to GetFileTitleA" 2ed
Alexandre Julliard
julliard at winehq.com
Tue Jan 14 12:21:44 CST 2003
liu spider <liuspider at yahoo.com> writes:
> short WINAPI GetFileTitleA(LPCSTR lpFile, LPSTR lpTitle, UINT cbBuf)
> {
> - int i, len;
> + int ret;
> + UNICODE_STRING strWFile, strWTitle;
> + RtlCreateUnicodeStringFromAsciiz(&strWFile, lpFile);
> + RtlCreateUnicodeStringFromAsciiz(&strWTitle,lpTitle);
> + ret = GetFileTitleW(strWFile.Buffer, strWTitle.Buffer, cbBuf * sizeof(WCHAR));
lpTitle is an output parameter, you can't convert it to Unicode on
input, you should allocate a buffer instead.
--
Alexandre Julliard
julliard at winehq.com
More information about the wine-devel
mailing list