Цитата:
Сообщение от mira
2 м можно захватить одним потоком неск.раз (ессно чтоб освободить нада стокаже раз вызвать release) секция же скорее всего "сломаетса" при двух ентерах или ливах.
|
да вы, батенька, фантазёр:
Цитата:
After a thread has ownership of a critical section, it can make additional calls to EnterCriticalSection or TryEnterCriticalSection without blocking its execution. This prevents a thread from deadlocking itself while waiting for a critical section that it already owns. The thread enters the critical section each time EnterCriticalSection and TryEnterCriticalSection succeed. A thread must call LeaveCriticalSection once for each time that it entered the critical section.
|