Tôi có một ứng dụng đang khóa trên luồng GUI, và tôi đã sử dụng WinDbg, cùng với lệnh "! Clrstack" để nhận dấu vết ngăn xếp này, nhưng tôi không thể tìm ra nơi vấn đề là. Tất cả các phương pháp này trông giống như các phương pháp khung và không có phương pháp nào của tôi. Bất kì sự trợ giúp nào đều được đánh giá cao. Tôi xin lỗi vì những dòng dàiCần trợ giúp giải mã dấu vết ngăn xếp C#
OS Thread Id: 0x724 (0)
ESP EIP
0012ec88 7c90e4f4 [HelperMethodFrame_1OBJ: 0012ec88] System.Threading.WaitHandle.WaitOneNative(Microsoft.Win32.SafeHandles.SafeWaitHandle, UInt32, Boolean, Boolean)
0012ed34 792b687f System.Threading.WaitHandle.WaitOne(Int64, Boolean)
0012ed50 792b6835 System.Threading.WaitHandle.WaitOne(Int32, Boolean)
0012ed64 7b6f192f System.Windows.Forms.Control.WaitForWaitHandle(System.Threading.WaitHandle)
0012ed78 7ba2d0bb System.Windows.Forms.Control.MarshaledInvoke(System.Windows.Forms.Control, System.Delegate, System.Object[], Boolean)
0012ee18 7b6f328c System.Windows.Forms.Control.Invoke(System.Delegate, System.Object[])
0012ee4c 7b920717 System.Windows.Forms.WindowsFormsSynchronizationContext.Send(System.Threading.SendOrPostCallback, System.Object)
0012ee64 7a924102 Microsoft.Win32.SystemEvents+SystemEventInvokeInfo.Invoke(Boolean, System.Object[])
0012ee98 7a922833 Microsoft.Win32.SystemEvents.RaiseEvent(Boolean, System.Object, System.Object[])
0012eee4 7a923d2f Microsoft.Win32.SystemEvents.OnUserPreferenceChanged(Int32, IntPtr, IntPtr)
0012ef04 7aa8f184 Microsoft.Win32.SystemEvents.WindowProc(IntPtr, Int32, IntPtr, IntPtr)
0012ef08 003620a4 [InlinedCallFrame: 0012ef08]
0012f0cc 7b1d8cce System.Windows.Forms.Application+ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32, Int32, Int32)
0012f168 7b1d8937 System.Windows.Forms.Application+ThreadContext.RunMessageLoopInner(Int32, System.Windows.Forms.ApplicationContext)
0012f1bc 7b1d8781 System.Windows.Forms.Application+ThreadContext.RunMessageLoop(Int32, System.Windows.Forms.ApplicationContext)
0012f1ec 7b195911 System.Windows.Forms.Application.Run(System.Windows.Forms.Form)
0012f200 00eb0ebb WinForms1.Program.Main()
0012f69c 79e71b4c [GCFrame: 0012f69c]
Bạn đang cố gắng sửa đổi đối tượng GUI từ chuỗi không sở hữu? Nếu vậy bạn có thể chạy vào vấn đề InvokeRequired. –
Theo như tôi biết tôi không thực hiện bất kỳ thao tác chéo nào. Tôi nghĩ rằng tôi sẽ có một đánh giá mã mở rộng để theo dõi điều này. –
Nếu bất kỳ ai đọc chủ đề này đang xử lý vấn đề này liên tục, một cách để buộc một repro là thiết lập một biến môi trường trong một vòng lặp. Đây là một tệp mẫu .cmd đặt một biến môi trường toàn hệ thống mỗi ~ 5 giây: mã: top setx.exe foo thanh ping.exe -n 5 localhost> nul goto top – JohnW