According to http://fpc.freedoors.org/fpc-2.2.0.source/rtl/win/sysosh.inc the definition should be something like the patch below says.
The copyright on this stuff is LGPL so I can take it over. I'm not sure how this can cause crashes in your application though. Danny pavilion: {40} svn diff winbase.h Index: winbase.h =================================================================== --- winbase.h (revision 1246) +++ winbase.h (working copy) @@ -807,7 +807,16 @@ DWORD ContentionCount; DWORD Spare [2]; } CRITICAL_SECTION_DEBUG,*PCRITICAL_SECTION_DEBUG; +#ifdef UNDER_CE typedef struct _CRITICAL_SECTION { + DWORD LockCount; // Nesting count on critical section + HANDLE OwnerThread; // Handle of owner thread + HANDLE hCrit; // Handle to this critical section + DWORD needtrap; // Trap in when freeing critical section + DWORD dwContentions; // Count of contentions +} CRITICAL_SECTION,*PCRITICAL_SECTION,*LPCRITICAL_SECTION; +#else +typedef struct _CRITICAL_SECTION { PCRITICAL_SECTION_DEBUG DebugInfo; LONG LockCount; LONG RecursionCount; @@ -815,6 +824,7 @@ HANDLE LockSemaphore; DWORD SpinCount; } CRITICAL_SECTION,*PCRITICAL_SECTION,*LPCRITICAL_SECTION; +#endif typedef struct _SYSTEMTIME { WORD wYear; WORD wMonth; pavilion: {41} On Mon, 2009-05-18 at 11:58 +0200, Johnny Willemsen wrote: > Hi, > > > I've looked on the internet a bit and can't find much info. > > > > We've inherited the declarations we use from another project, it is not > > CE specific. So the issue might be that some versions of Windows do > > have > > a RecursionCount field, and otherd do not. > > The CRITICAL_SECTION definition is really different for WinCE. > > > Does this difference bother you ? Do you have more accurate information > > on what should be in the CE version of this struct ? > > Yes, we think it is a problem. The struct WinCE itself uses is different > then the one using with CEGCC, this could explain the crashes and the > hanging tests we see. > > Search for CRITICAL_SECTION and hCrit on Google. hCrit is one of the fields > on CE that is not there with regular Windows. We could send you the links, > but don't want to give links you are not allowed to use ;-) > > Johnny > > > ------------------------------------------------------------------------------ > Crystal Reports - New Free Runtime and 30 Day Trial > Check out the new simplified licensing option that enables > unlimited royalty-free distribution of the report engine > for externally facing server and web deployment. > http://p.sf.net/sfu/businessobjects > _______________________________________________ > Cegcc-devel mailing list > Cegcc-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/cegcc-devel > -- Danny Backx ; danny.backx - at - scarlet.be ; http://danny.backx.info ------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects _______________________________________________ Cegcc-devel mailing list Cegcc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/cegcc-devel