Code:
/ DotNET / DotNET / 8.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
- DropDownList.cs
- BamlResourceSerializer.cs
- DataGridViewImageCell.cs
- TextBox.cs
- PanelStyle.cs
- parserscommon.cs
- EventBuilder.cs
- WindowsListViewItemStartMenu.cs
- VideoDrawing.cs
- ScanQueryOperator.cs
- DataRelationPropertyDescriptor.cs
- PropertyEmitter.cs
- SQLRoleProvider.cs
- DefaultEventAttribute.cs
- QuaternionRotation3D.cs
- HttpContextServiceHost.cs
- DbParameterCollectionHelper.cs
- DataGridViewCellValueEventArgs.cs
- BinaryFormatterSinks.cs
- VectorAnimation.cs
- isolationinterop.cs
- DateTimeParse.cs
- PictureBox.cs
- RankException.cs
- TableSectionStyle.cs
- SimpleHandlerBuildProvider.cs
- SqlConnectionString.cs
- unitconverter.cs
- SchemaMapping.cs
- DBSchemaTable.cs
- StronglyTypedResourceBuilder.cs
- XmlParser.cs
- TypeReference.cs
- XmlSchemaSequence.cs
- SqlConnectionPoolGroupProviderInfo.cs
- SocketException.cs
- AddInIpcChannel.cs
- SafeUserTokenHandle.cs
- CodeSnippetTypeMember.cs
- Literal.cs
- CodeDomConfigurationHandler.cs
- ComponentCache.cs
- FastPropertyAccessor.cs
- BitmapEncoder.cs
- ActivityExecutorDelegateInfo.cs
- ProfileSettingsCollection.cs
- HttpContextServiceHost.cs
- ObservableCollection.cs
- ResizeBehavior.cs
- Options.cs
- ContentControl.cs
- ServiceTimeoutsElement.cs
- RightsManagementPermission.cs
- Span.cs
- IsolationInterop.cs
- LinkArea.cs
- UnmanagedMemoryStreamWrapper.cs
- WindowsSecurityToken.cs
- DatatypeImplementation.cs
- PageSetupDialog.cs
- GrammarBuilderDictation.cs
- RoleManagerModule.cs
- CustomAttributeSerializer.cs
- DataRowChangeEvent.cs
- EventWaitHandleSecurity.cs
- CookieProtection.cs
- ApplicationFileParser.cs
- CompilerWrapper.cs
- SoapAttributeAttribute.cs
- Events.cs
- Label.cs
- ScriptingAuthenticationServiceSection.cs
- ReflectionHelper.cs
- MtomMessageEncodingElement.cs
- ListChangedEventArgs.cs
- EntryIndex.cs
- Operator.cs
- AttributeData.cs
- OleDbParameter.cs
- DragDrop.cs
- Propagator.Evaluator.cs
- Repeater.cs
- EditableLabelControl.cs
- TreeBuilder.cs
- SaveFileDialogDesigner.cs
- AsymmetricSignatureDeformatter.cs
- SQLDateTime.cs
- HttpPostProtocolImporter.cs
- OptimizerPatterns.cs
- DataKeyArray.cs
- TranslateTransform.cs
- DelegateCompletionCallbackWrapper.cs
- OperandQuery.cs
- ToolStripSplitButton.cs
- ViewPort3D.cs
- DataTableCollection.cs
- GB18030Encoding.cs
- ConfigXmlElement.cs
- SuppressIldasmAttribute.cs
- _CookieModule.cs