Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / Services / Monitoring / system / Diagnosticts / processwaithandle.cs / 1 / processwaithandle.cs
using System; using System.Threading; using Microsoft.Win32; using Microsoft.Win32.SafeHandles; using System.Runtime.InteropServices; namespace System.Diagnostics { internal class ProcessWaitHandle : WaitHandle { 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; } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TextBlock.cs
- WebScriptEnablingBehavior.cs
- TableItemProviderWrapper.cs
- XmlNodeChangedEventArgs.cs
- XPathSelfQuery.cs
- DragCompletedEventArgs.cs
- IssuanceTokenProviderBase.cs
- CacheDependency.cs
- WebPartTracker.cs
- TextBox.cs
- TreeView.cs
- ElementsClipboardData.cs
- SmtpSpecifiedPickupDirectoryElement.cs
- Memoizer.cs
- XmlTextReaderImpl.cs
- DescendantOverDescendantQuery.cs
- SystemIcmpV6Statistics.cs
- Utils.cs
- DbFunctionCommandTree.cs
- AssociationProvider.cs
- WeakReferenceKey.cs
- RequestResizeEvent.cs
- AttachedPropertyBrowsableForTypeAttribute.cs
- RC2CryptoServiceProvider.cs
- WinCategoryAttribute.cs
- XPathMultyIterator.cs
- PersistenceTypeAttribute.cs
- CompoundFileStorageReference.cs
- Scene3D.cs
- SelectionEditingBehavior.cs
- ConditionalAttribute.cs
- TextServicesPropertyRanges.cs
- ProfilePropertyMetadata.cs
- DataGridDesigner.cs
- RuntimeWrappedException.cs
- OptimalTextSource.cs
- RuntimeConfigLKG.cs
- CodeArgumentReferenceExpression.cs
- XmlKeywords.cs
- DecoderFallback.cs
- XmlSignificantWhitespace.cs
- ApplicationTrust.cs
- DataGridViewRowCollection.cs
- ReadOnlyDictionary.cs
- KeySpline.cs
- ImageListStreamer.cs
- Color.cs
- EntityWithKeyStrategy.cs
- CreateUserWizard.cs
- XmlQueryOutput.cs
- DesignOnlyAttribute.cs
- SeekableReadStream.cs
- AmbientLight.cs
- RelationshipFixer.cs
- PathGradientBrush.cs
- _AutoWebProxyScriptEngine.cs
- SystemParameters.cs
- SecurityTokenValidationException.cs
- RevocationPoint.cs
- PointLightBase.cs
- IntSecurity.cs
- RealProxy.cs
- ManagementObjectSearcher.cs
- ListControlStringCollectionEditor.cs
- DataTableMappingCollection.cs
- HostedNamedPipeTransportManager.cs
- MediaCommands.cs
- TextRangeBase.cs
- DataObject.cs
- RemotingConfigParser.cs
- TraceSection.cs
- PriorityRange.cs
- SystemTcpConnection.cs
- AspCompat.cs
- _NetworkingPerfCounters.cs
- Path.cs
- GiveFeedbackEvent.cs
- TreeNodeBindingCollection.cs
- ContainerFilterService.cs
- FloaterBaseParaClient.cs
- Highlights.cs
- ExpressionCopier.cs
- PerformanceCounterCategory.cs
- PriorityQueue.cs
- ScalarType.cs
- FrameworkObject.cs
- ObjectDataSourceFilteringEventArgs.cs
- FunctionImportElement.cs
- Enum.cs
- ContentPosition.cs
- DateTime.cs
- WmlPageAdapter.cs
- ToolStripEditorManager.cs
- XmlMapping.cs
- compensatingcollection.cs
- AttributeParameterInfo.cs
- EntityType.cs
- AddressAccessDeniedException.cs
- _TransmitFileOverlappedAsyncResult.cs
- ThreadStaticAttribute.cs