You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
using System.Threading;
|
|
|
|
namespace SharpCifs.Util.Sharpen
|
|
{
|
|
internal class ReentrantLock
|
|
{
|
|
public void Lock()
|
|
{
|
|
Monitor.Enter(this);
|
|
}
|
|
|
|
public bool TryLock()
|
|
{
|
|
return Monitor.TryEnter(this);
|
|
}
|
|
|
|
public void Unlock()
|
|
{
|
|
Monitor.Exit(this);
|
|
}
|
|
}
|
|
}
|