Re: Wrong call convention for SHAllocShared & co?

2004-08-21 Thread Ivan Leo Puoti
>Hence my confusion and my call for help.
The solution that comes in mind is write a test program and find out.

Ivan.





Re: Wrong call convention for SHAllocShared & co?

2004-08-21 Thread Francois Gouget
On Sun, 22 Aug 2004, Ivan Leo Puoti wrote:

> > So who's right? The platform SDK that says this is a cdecl function or
> > Wine's headers?
> If the SDK is wrong and is diffrent from the windows implementation, then
> programs calling that function will have
> problems bacause of imcompatible headers between the ones used to build windows
> and the SDK ones used to build the program, no?

Yes and that would seem to indicate that the Platform SDK is correct.

However if Wine's implementation is wrong then Windows applications that
call this API should crash and we should have noticed, no? So that seems
to indicate that Wine's implementation must be correct.

Hence my confusion and my call for help.


-- 
Francois Gouget [EMAIL PROTECTED]http://fgouget.free.fr/
 Stolen from an Internet user:
  "f u cn rd ths, u cn gt a gd jb n cmptr prgrmmng !"



Re: Wrong call convention for SHAllocShared & co?

2004-08-21 Thread Ivan Leo Puoti
> So who's right? The platform SDK that says this is a cdecl function or
> Wine's headers?
If the SDK is wrong and is diffrent from the windows implementation, then
programs calling that function will have
problems bacause of imcompatible headers between the ones used to build windows
and the SDK ones used to build the program, no?

Ivan.





Re: Wrong call convention for SHAllocShared & co?

2004-08-21 Thread Francois Gouget

Still looking in undocshell.h, I see we have:

BOOL WINAPI GetFileNameFromBrowse(
HWND hwndOwner,
LPSTR lpstrFile,
DWORD nMaxFile,
LPCSTR lpstrInitialDir,
LPCSTR lpstrDefExt,
LPCSTR lpstrFilter,
LPCSTR lpstrTitle);

But in the Platform SDK's the prototype is:

SHSTDAPI_(BOOL) GetFileNameFromBrowse(HWND hwnd, LPWSTR pszFilePath,
 UINT cbFilePath,LPCWSTR pszWorkingDir, LPCWSTR pszDefExt,
 LPCWSTR pszFilters, LPCWSTR pszTitle);

So is this an Ansi or a Unicode function? Or maybe it's one of these AW
Ansi/Unicode functions? In that case the implementation is wrong because
it definitely expects to receive Ansi strings.

Same question for PickIconDlg().

-- 
Francois Gouget [EMAIL PROTECTED]http://fgouget.free.fr/
1 + e ^ ( i * pi ) = 0