10 references to ThreadMayHaveLock
System.Data (10)
fx\src\data\System\Data\SqlClient\SqlInternalConnectionTds.cs (3)
1086
Debug.Assert(!ThreadHasParserLockForClose || _parserLock.
ThreadMayHaveLock
(), "Thread claims to have parser lock, but lock is not taken");
2004
Debug.Assert(obtainParserLock || _parserLock.
ThreadMayHaveLock
(), "Thread claims to have lock, but lock is not taken");
2665
Debug.Assert(_parserLock.
ThreadMayHaveLock
(), "Should not modify ThreadHasParserLockForClose without taking the lock first");
fx\src\data\System\Data\SqlClient\TdsParser.cs (6)
1232
Debug.Assert(!callerHasConnectionLock || _connHandler._parserLock.
ThreadMayHaveLock
(), "Caller claims to have lock, but connection lock is not taken");
1456
Debug.Assert(_connHandler._parserLock.
ThreadMayHaveLock
(), "Thread is writing without taking the connection lock");
7718
Debug.Assert(!_connHandler.ThreadHasParserLockForClose || _connHandler._parserLock.
ThreadMayHaveLock
(), "Thread claims to have parser lock, but lock is not taken");
7910
Debug.Assert(_connHandler._parserLock.
ThreadMayHaveLock
(), "Should not be calling into FailureCleanup without first taking the parser lock");
7954
Debug.Assert(needToTakeParserLock || _connHandler._parserLock.
ThreadMayHaveLock
(), "Thread or caller claims to have connection lock, but lock is not taken");
8053
Debug.Assert(firstCall || _connHandler._parserLock.
ThreadMayHaveLock
(), "Connection lock not taken after the first call");
fx\src\data\System\Data\SqlClient\TdsParserStateObject.cs (1)
3076
Debug.Assert(Parser.Connection._parserLock.
ThreadMayHaveLock
(), "Thread is writing without taking the connection lock");