Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Services / Monitoring / system / Diagnosticts / processwaithandle.cs / 1305376 / processwaithandle.cs
using System; using System.Threading; using Microsoft.Win32; using Microsoft.Win32.SafeHandles; using System.Runtime.InteropServices; using System.Runtime.Versioning; namespace System.Diagnostics { internal class ProcessWaitHandle : WaitHandle { [ResourceExposure(ResourceScope.None)] [ResourceConsumption(ResourceScope.Machine, ResourceScope.Machine)] internal ProcessWaitHandle( SafeProcessHandle processHandle): base() { SafeWaitHandle waitHandle = null; bool succeeded = NativeMethods.DuplicateHandle( new HandleRef(this, NativeMethods.GetCurrentProcess()), processHandle, new HandleRef(this, NativeMethods.GetCurrentProcess()), out waitHandle, 0, false, NativeMethods.DUPLICATE_SAME_ACCESS); if (!succeeded) { Marshal.ThrowExceptionForHR(Marshal.GetHRForLastWin32Error()); } this.SafeWaitHandle = waitHandle; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- PolicyStatement.cs
- ConsoleEntryPoint.cs
- HandlerBase.cs
- DateTimeOffsetStorage.cs
- RewritingSimplifier.cs
- XmlQueryStaticData.cs
- RunClient.cs
- configsystem.cs
- RoutedUICommand.cs
- DetailsViewModeEventArgs.cs
- CategoryAttribute.cs
- DataDocumentXPathNavigator.cs
- OutputCacheSection.cs
- TextLineResult.cs
- XmlLanguageConverter.cs
- XmlByteStreamWriter.cs
- SmiEventStream.cs
- DynamicFilterExpression.cs
- EventMappingSettings.cs
- PackageDigitalSignature.cs
- ParentQuery.cs
- ContextMenu.cs
- SQLUtility.cs
- ExpressionNormalizer.cs
- Interlocked.cs
- TemplateBindingExpressionConverter.cs
- Container.cs
- PagesChangedEventArgs.cs
- ConnectionManagementElementCollection.cs
- StringAttributeCollection.cs
- Canvas.cs
- CurrentChangingEventManager.cs
- FactoryId.cs
- PathSegmentCollection.cs
- MenuItemBinding.cs
- DataGridViewColumnDesigner.cs
- RegexWriter.cs
- RegistryKey.cs
- QueryInterceptorAttribute.cs
- RegexParser.cs
- ApplicationInfo.cs
- OutOfMemoryException.cs
- CapabilitiesSection.cs
- TraceLevelStore.cs
- ActivityDesignerLayoutSerializers.cs
- ExtensionQuery.cs
- SrgsText.cs
- ValidationEventArgs.cs
- CategoryGridEntry.cs
- CounterSet.cs
- SqlTypesSchemaImporter.cs
- CodeArrayCreateExpression.cs
- Tag.cs
- Maps.cs
- XsltOutput.cs
- SHA384Managed.cs
- OdbcCommand.cs
- AstTree.cs
- DockPattern.cs
- bindurihelper.cs
- DataGridColumnCollection.cs
- BitVector32.cs
- X509ChainPolicy.cs
- CodePageEncoding.cs
- MasterPage.cs
- ActivityCodeDomSerializer.cs
- DoneReceivingAsyncResult.cs
- FormViewCommandEventArgs.cs
- ServiceContractAttribute.cs
- BreakSafeBase.cs
- PageCatalogPartDesigner.cs
- D3DImage.cs
- ExpressionTextBoxAutomationPeer.cs
- UdpSocket.cs
- FlowNode.cs
- HostedTransportConfigurationManager.cs
- SerTrace.cs
- CommentEmitter.cs
- DataTableReaderListener.cs
- PointLightBase.cs
- CellCreator.cs
- FieldDescriptor.cs
- SwitchAttribute.cs
- FieldDescriptor.cs
- InvokePatternIdentifiers.cs
- DataGridDesigner.cs
- _SslState.cs
- ItemType.cs
- TextTreeFixupNode.cs
- FlowchartDesigner.Helpers.cs
- PageParserFilter.cs
- DataGrid.cs
- TextSelection.cs
- DatatypeImplementation.cs
- ThicknessAnimationBase.cs
- NavigationProgressEventArgs.cs
- GridViewPageEventArgs.cs
- FlowchartDesignerCommands.cs
- EmptyReadOnlyDictionaryInternal.cs
- WebPartMenu.cs