By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,257 Members | 2,812 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,257 IT Pros & Developers. It's quick & easy.

My Winform application UI hang after taking remote control.

P: 2
My Winform application run on machine A. After sometime when i took remote control of machine A from machine B. I saw my application execute my script but application UI is in hung state.

So I used WinDbg(x64) for debug i saw application main thread is stuck with this log

Expand|Select|Wrap|Line Numbers
  1.  
  2. ntdll.dll!NtWaitForSingleObject+0xa
  3. mswsock.dll!WSPStartup+0x8cd5
  4. mswsock.dll!WSPStartup+0xad4e
  5. ws2_32.dll!recv+0x13c
  6. [Native Frame: IL Method without Metadata]
  7. [Managed to Unmanaged Transition]
  8. System.dll!System.Net.Sockets.Socket.Receive+0xfa
  9. System.dll!System.Net.Sockets.Socket.Receive+0x28
  10. System.Runtime.Remoting.dll!System.Runtime.Remoting.Channels.SocketStream.Read+0x34
  11. System.dll!System.Net.StreamFramer.ReadMessage+0x4d
  12. System.dll!System.Net.Security.NegoState.StartReceiveBlob+0x1e
  13. System.dll!System.Net.Security.NegoState.StartSendBlob+0x4bb
  14. System.dll!System.Net.Security.NegoState.ProcessAuthentication+0xc4
  15. System.dll!System.Net.Security.NegotiateStream.AuthenticateAsClient+0x22
  16. System.Runtime.Remoting.dll!System.Runtime.Remoting.Channels.Tcp.TcpClientTransportSink.CreateAuthenticatedStream+0xca
  17. System.Runtime.Remoting.dll!System.Runtime.Remoting.Channels.Tcp.TcpClientTransportSink.CreateSocketHandler+0x47
  18. System.Runtime.Remoting.dll!System.Runtime.Remoting.Channels.RemoteConnection.CreateNewSocket+0xd0
  19. System.Runtime.Remoting.dll!System.Runtime.Remoting.Channels.SocketCache.GetSocket+0x1bc
  20. System.Runtime.Remoting.dll!System.Runtime.Remoting.Channels.Tcp.TcpClientTransportSink.SendRequestWithRetry+0x162
  21. System.Runtime.Remoting.dll!System.Runtime.Remoting.Channels.Tcp.TcpClientTransportSink.AsyncProcessRequest+0x27
  22. System.Runtime.Remoting.dll!System.Runtime.Remoting.Channels.BinaryClientFormatterSink.AsyncProcessMessage+0xa8
  23. mscorlib.dll!System.Runtime.Remoting.Messaging.ClientContextTerminatorSink.AsyncProcessMessageCallback+0x79
  24. [Unmanaged to Managed Transition]
  25. clr.dll+0xa7f3
  26. clr.dll+0xa6de
  27. clr.dll!CopyPDBs+0x288b
  28. clr.dll!CopyPDBs+0x2aa2
  29. clr.dll!CreateApplicationContext+0x1b3e
  30. [Managed to Unmanaged Transition]
  31. mscorlib.dll!System.Runtime.Remoting.Messaging.ClientContextTerminatorSink.AsyncProcessMessage+0x29c
  32. mscorlib.dll!System.Runtime.Remoting.Messaging.EnvoyTerminatorSink.AsyncProcessMessage+0xdc
  33. mscorlib.dll!System.Runtime.Remoting.Proxies.RemotingProxy.InternalInvokeAsync+0xf6
  34. mscorlib.dll!System.Runtime.Remoting.Proxies.RemotingProxy.InternalInvoke+0x5f2
  35. mscorlib.dll!System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke+0x1f4
  36. [Unmanaged to Managed Transition]
  37. clr.dll+0x17292
  38. clr.dll!CreateApplicationContext+0x137a8
  39. clr.dll!CreateApplicationContext+0x2456
  40. clr.dll+0x17194
  41. [Managed to Unmanaged Transition]
  42. Microsoft.VisualBasic.dll!Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run+0x648
  43. ExecutionAgent.exe!Cres.Execution.Agent.My.MyApplication.Main+0x5e
  44. [Unmanaged to Managed Transition]
  45. clr.dll+0xa7f3
  46. clr.dll+0xa6de
  47. clr.dll+0xae76
  48. clr.dll!CorExeMain+0x35e9
  49. clr.dll!CorExeMain+0x392e
  50. clr.dll!CorExeMain+0x3827
  51. clr.dll!CorExeMain+0x37aa
  52. clr.dll!CorExeMain+0x3702
  53. clr.dll!CorExeMain+0x14
  54. mscoreei.dll!CorExeMain+0x5d
  55. MSCOREE.DLL!CorExeMain+0x69
  56. KERNEL32.dll!BaseThreadInitThunk+0xd
  57. ntdll.dll!RtlUserThreadStart+0x21
  58.  
  59.  
Any ideas on what is causing this problem.

Thanks
Nov 20 '17 #1
Share this Question
Share on Google+
2 Replies


P: 2
Using STR when i connect or disconnect remote control application UI hang. I have another logs when i debug using WinDbg(x64)

Expand|Select|Wrap|Line Numbers
  1. ntdll.dll!ZwWaitForMultipleObjects+0x14
  2. KERNELBASE.dll!WaitForMultipleObjectsEx+0xf0
  3. USER32.dll!MsgWaitForMultipleObjectsEx+0x1e0
  4. combase.dll!Ordinal111+0x63b
  5. combase.dll!CoGetCurrentLogicalThreadId+0x20f
  6. combase.dll!CoWaitForMultipleHandles+0xb3
  7. clr.dll!MetaDataGetDispenser+0xcd4a
  8. clr.dll!MetaDataGetDispenser+0xccb4
  9. clr.dll!MetaDataGetDispenser+0x76efd
  10. clr.dll!MetaDataGetDispenser+0x8f4d5
  11. [Managed to Unmanaged Transition]
  12. mscorlib.dll!System.Threading.WaitHandle.InternalWaitOne+0x1b
  13. mscorlib.dll!System.Threading.WaitHandle.WaitOne+0x2e
  14. System.Windows.Forms.dll!System.Windows.Forms.Control.WaitForWaitHandle+0x1ed
  15. System.Windows.Forms.dll!System.Windows.Forms.Control.MarshaledInvoke+0x431
  16. System.Windows.Forms.dll!System.Windows.Forms.Control.Invoke+0x60
  17. System.Windows.Forms.dll!System.Windows.Forms.WindowsFormsSynchronizationContext.Send+0x74
  18. System.dll!SystemEventInvokeInfo.Invoke+0x9c
  19. System.dll!Microsoft.Win32.SystemEvents.RaiseEvent+0x129
  20. System.dll!Microsoft.Win32.SystemEvents.OnDisplaySettingsChanging+0x76
  21. System.dll!Microsoft.Win32.SystemEvents.WindowProc+0x272
  22. [Unmanaged to Managed Transition]
  23. [Native Frame: IL Method without Metadata]
  24. clr.dll+0x21fe
  25. USER32.dll!CallWindowProcW+0x4d0
  26. USER32.dll!DispatchMessageW+0x1af
  27. [Native Frame: IL Method without Metadata]
  28. [Managed to Unmanaged Transition]
  29. System.Windows.Forms.dll!ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop+0x33e
  30. System.Windows.Forms.dll!ThreadContext.RunMessageLoopInner+0x1c6
  31. System.Windows.Forms.dll!ThreadContext.RunMessageLoop+0x51
  32. Microsoft.VisualBasic.dll!Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun+0xa5
  33. Microsoft.VisualBasic.dll!Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.DoApplicationModel+0x95
  34. Microsoft.VisualBasic.dll!Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run+0x3ca
  35. ExecutionAgent.exe!Execution.Agent.My.MyApplication.Main+0x64
  36. [Unmanaged to Managed Transition]
  37. clr.dll!LogHelp_LogAssert+0x1bf3
  38. clr.dll!LogHelp_LogAssert+0x1ac5
  39. clr.dll!LogHelp_LogAssert+0x27cd
  40. clr.dll!SetRuntimeInfo+0x1580
  41. clr.dll!SetRuntimeInfo+0x1dca
  42. clr.dll!SetRuntimeInfo+0x1c87
  43. clr.dll!SetRuntimeInfo+0x161d
  44. clr.dll!SetRuntimeInfo+0x1402
  45. clr.dll!CorExeMain+0x14
  46. mscoreei.dll!CorExeMain+0x6d
  47. MSCOREE.DLL!CorExeMain+0x6c
  48. KERNEL32.dll!BaseThreadInitThunk+0x14
  49. ntdll.dll!RtlUserThreadStart+0x21
  50.  
Nov 22 '17 #2

Frinavale
Expert Mod 5K+
P: 9,731
Well there is a problem getting data across your network (sockets).

I'm not 100% sure what is causing this but the first thing I would check is permissions.

Make sure that the users are permitted to use the resources necessary to run the application across the network like this.

The reason I suspect permissions is because, in your first post, you are having problems receiving data in the ProcessAuthentication method...

Sorry I can't be much more help.
Nov 28 '17 #3

Post your reply

Sign in to post your reply or Sign up for a free account.