We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7806c5c commit 8d1bdc5Copy full SHA for 8d1bdc5
snippets/csharp/Microsoft.Win32.SafeHandles/SafeWaitHandle/Overview/sample.cs
@@ -56,8 +56,7 @@ public UnmanagedMutex(string Name)
56
57
public void Create()
58
{
59
- if (nameValue == null || nameValue.Length == 0)
60
- throw new ArgumentException(nameof(nameValue));
+ ArgumentException.ThrowIfNullOrEmpty(nameValue);
61
62
handleValue = CreateMutex(mutexAttrValue,
63
true, nameValue);
0 commit comments