25 references to Errors
System.Diagnostics.PerformanceCounter (25)
src\runtime\src\libraries\Common\src\Microsoft\Win32\SafeHandles\SafePerfProviderHandle.cs (1)
17
Debug.Assert(Status == (uint)Interop.
Errors
.ERROR_SUCCESS, "PerfStopProvider() fails");
src\runtime\src\libraries\System.Private.CoreLib\src\Microsoft\Win32\SafeHandles\SafeRegistryHandle.cs (1)
37
Interop.Advapi32.RegCloseKey(handle) == Interop.
Errors
.ERROR_SUCCESS;
System\Diagnostics\CounterSampleCalculator.cs (1)
95
if (result != Interop.
Errors
.ERROR_SUCCESS)
System\Diagnostics\PerformanceCounterLib.cs (6)
1222
if (res == Interop.
Errors
.ERROR_ACCESS_DENIED)
1269
throw new Win32Exception(Interop.
Errors
.ERROR_ACCESS_DENIED);
1313
case Interop.
Errors
.ERROR_INVALID_HANDLE:
1319
case Interop.
Errors
.ERROR_NOT_READY:
1320
case Interop.
Errors
.ERROR_LOCK_FAILED:
1321
case Interop.
Errors
.ERROR_BUSY:
System\Diagnostics\PerformanceData\CounterSet.cs (3)
204
uint Status = (uint)Interop.
Errors
.ERROR_SUCCESS;
251
if (Status != (uint)Interop.
Errors
.ERROR_SUCCESS)
255
(uint)Interop.
Errors
.ERROR_ALREADY_EXISTS => new InvalidOperationException(SR.Format(SR.Perflib_Argument_CounterSetAlreadyRegister, _counterSet)),
System\Diagnostics\PerformanceData\CounterSetInstance.cs (4)
37
int Status = (int)((_nativeInst != null) ? Interop.
Errors
.ERROR_SUCCESS : Marshal.GetLastWin32Error());
51
case (int)Interop.
Errors
.ERROR_ALREADY_EXISTS:
54
case (int)Interop.
Errors
.ERROR_NOT_FOUND:
57
case (int)Interop.
Errors
.ERROR_INVALID_PARAMETER:
System\Diagnostics\PerformanceData\CounterSetInstanceCounterDataSet.cs (2)
146
if (Status != (uint)Interop.
Errors
.ERROR_SUCCESS)
153
(uint)Interop.
Errors
.ERROR_NOT_FOUND => new InvalidOperationException(SR.Format(SR.Perflib_InvalidOperation_CounterRefValue, _instance._counterSet._counterSet, CounterDef.Key, _instance._instName)),
System\Diagnostics\PerformanceData\PerfProviderCollection.cs (1)
22
if (Status != (uint)Interop.
Errors
.ERROR_SUCCESS)
System\Diagnostics\PerformanceDataRegistryKey.cs (3)
35
if (ret == Interop.
Errors
.ERROR_DLL_INIT_FAILED)
64
while (Interop.
Errors
.ERROR_MORE_DATA == (ret = Interop.Advapi32.RegQueryValueEx(_hkey, name, lpReserved: null, ref type, data, ref sizeInput)))
124
if (errorCode == Interop.
Errors
.ERROR_ACCESS_DENIED)
System\Diagnostics\SharedPerformanceCounter.cs (3)
1306
if ((error == Interop.
Errors
.ERROR_INVALID_PARAMETER) && procHandle.IsInvalid)
1717
if ((Marshal.GetLastWin32Error() != Interop.
Errors
.ERROR_ACCESS_DENIED) || !_fileMappingHandle.IsInvalid)
1727
if ((Marshal.GetLastWin32Error() != Interop.
Errors
.ERROR_FILE_NOT_FOUND) || !_fileMappingHandle.IsInvalid)