我有被擊中的消息診斷的ObjectDisposedException「安全把手已關閉」
安全手柄已被關閉的ObjectDisposedException C#應用程序
出現這種情況,只要我啓動應用。
可悲的是堆棧跟蹤確實沒有幫助(見下文)。有什麼方法可以讓我確定在這裏異步嘗試哪個呼叫?
DoAsyncCall()確實暗示了一個異步方法調用?
mscorlib.dll中!System.Threading.EventWaitHandle.Set()+ 0xe字節
mscorlib.dll中!System.Runtime.Remoting.Messaging.AsyncResult.SyncProcessMessage(System.Runtime.Remoting.Messaging.IMessage MSG)+ 0x12f字節
mscorlib.dll中!System.Runtime.Remoting.Messaging.StackBuilderSink.AsyncProcessMessage(System.Runtime.Remoting.Messaging.IMessage 味精,System.Runtime.Remoting.Messaging.IMessageSink replySink = {系統。 Runtime.Remoting.Messaging.AsyncResult})+ 0x279 bytes
mscorlib.dll!System.Runtime.Remoting.Proxies.AgileAsyncWorkerItem.DoAsyncCall() + 0x32字節mscorlib.dll中!System.Runtime.Remoting.Proxies.AgileAsyncWorkerItem.ThreadPoolCallBack(對象 O)+ 0×28字節
mscorlib.dll中!System.Threading._ThreadPoolWaitCallback.WaitCallback_Context(對象 狀態)+值爲0x2F字節
mscorlib.dll中!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext 的ExecutionContext,System.Threading.ContextCallback回調,對象 狀態)+ 0x6f字節
mscorlib.dll中!System.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal(系統。 Threading._ThreadPoolWaitCallback tpWaitCallBack)+ 0x53 bytes
mscorlib.dll !System.Threading._ThreadPoolWaitCallback.PerformWaitCallback(對象 狀態)+ 0×59字節
感謝您 - 有什麼辦法解決我正在處理什麼和其他線程仍在使用它? – mchr 2010-12-17 17:57:10
@mchr:調試,中斷函數,'System.Runtime.InteropServices.SafeHandle.Dispose'。 – SLaks 2010-12-17 17:58:17