Home > Web Site Updates > CCriticalSectionEx, CThreadSafe & CThreadSafeScalar v1.02

CCriticalSectionEx, CThreadSafe & CThreadSafeScalar v1.02

January 11, 2009

Just to let everyone know that v1.02 of CCriticalSectionEx, CThreadSafe & CThreadSafeScalar has been released. Updates for this version include:

  • Updated copyright details
  • Removed VC 6 style AppWizard comments from the code
  • The code has now been updated to support VC 2005 or later only. It seems that even though ATL’s version of CCriticalSection now supports spin locks the MFC version of CCriticalSection still does not support them, hence still the need for CCriticalSectionEx.
  • Fixed a bug in CCriticalSectionEx::Lock where it handled the wrong SEH type being thrown. The code now only handles the STATUS_NO_MEMORY exception
  • Code now compiles cleanly using Code Analysis (/analyze)
  • Removed the bPreallocateEvent parameter from the CCriticalSectionEx::Init and CCriticalSectionEx’s overridden constructor.
  • Removed the call to Unlock in the CCriticalSectionEx destructor. This is to be consistent with MFC’s CCriticalSection class.
  • CCriticalSectionEx::Lock now throws a CMemoryException* exception. This is to be consistent with MFC’s CCriticalSection class.
  • The m_bLocked member variable of CCriticalSectionEx is now a bool instead of a BOOL. The IsLocked method has also been updated to return a bool.
Advertisements
Categories: Web Site Updates
%d bloggers like this: