A collegue found out the hard way that GetFileInformationByHandle was stomping the stack. Turns out that struct BY_HANDLE_FILE_INFORMATION was missing a field on CE <http://msdn.microsoft.com/en-us/library/aa914711.aspx>. I've applied this patch to fix this.
2009-12-10 Pedro Alves <pedroal...@users.sourceforge.net> * include/winbase.h (struct _BY_HANDLE_FILE_INFORMATION): Add missing `dwOID' field on CE. libmingwex.a's _fstat/fstat similarly corrupts the stack, because it uses GetFileInformationByHandle internally. That can only be fixed by building libmingwex.a with the fixed header, though. This makes me wonder if it's about time we split runtime (mingw/w32api) releases from compiler releases. Opinions on that? -- Pedro Alves Index: include/winbase.h =================================================================== --- include/winbase.h (revisão 1403) +++ include/winbase.h (revisão 1404) @@ -601,6 +601,9 @@ typedef struct _BY_HANDLE_FILE_INFORMATI DWORD nNumberOfLinks; DWORD nFileIndexHigh; DWORD nFileIndexLow; +#ifdef _WIN32_WCE + DWORD dwOID; +#endif } BY_HANDLE_FILE_INFORMATION,*LPBY_HANDLE_FILE_INFORMATION; typedef struct _DCB { DWORD DCBlength; ------------------------------------------------------------------------------ Return on Information: Google Enterprise Search pays you back Get the facts. http://p.sf.net/sfu/google-dev2dev _______________________________________________ Cegcc-devel mailing list Cegcc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/cegcc-devel