D
David Hardek
Does CCriticalSection work in VC++.NET.
I have code that uses CCriticalSection that worked in VC++
6.0 and when I try and run it in VC++.NET I run into an
exception error when I try and lock the critical section.
Just as a note I tried the CMutex sample program and it
works, but if I add in the following lines to that sample
program I get the same error I see in my application.
CCriticalSection criticalSection;
CSingleLock singleLock(&criticalSection)
singleLock.Lock(1000); // This call generates the
exception - doesn't look like criticalSection is getting
created correctly
singleLock.Unlock();
I have code that uses CCriticalSection that worked in VC++
6.0 and when I try and run it in VC++.NET I run into an
exception error when I try and lock the critical section.
Just as a note I tried the CMutex sample program and it
works, but if I add in the following lines to that sample
program I get the same error I see in my application.
CCriticalSection criticalSection;
CSingleLock singleLock(&criticalSection)
singleLock.Lock(1000); // This call generates the
exception - doesn't look like criticalSection is getting
created correctly
singleLock.Unlock();