View Code
1 public static ReaderWriterLock m_boolLogLock=new ReaderWriterLock();
2 try
3 {
4 if (m_boolLogLock != null)
5 {
6 m_boolLogLock.AcquireWriterLock(System.Threading.Timeout.Infinite);
7 }
8 }
9 catch
10 {
11 }
12 finally
13 {
14 if (m_boolLogLock != null)
15 {
16 m_boolLogLock.ReleaseWriterLock();
17 }
18 }
19 return true;
2 try
3 {
4 if (m_boolLogLock != null)
5 {
6 m_boolLogLock.AcquireWriterLock(System.Threading.Timeout.Infinite);
7 }
8 }
9 catch
10 {
11 }
12 finally
13 {
14 if (m_boolLogLock != null)
15 {
16 m_boolLogLock.ReleaseWriterLock();
17 }
18 }
19 return true;