[GH-ISSUE #930] RDP disconnect may causes freeze #2675

Closed
opened 2026-03-01 17:22:28 +03:00 by kerem · 14 comments
Owner

Originally created by @itagagaki on GitHub (May 12, 2025).
Original GitHub issue: https://github.com/1Remote/1Remote/issues/930

Originally assigned to: @VShawn on GitHub.

Reproducibility is random.

This did not happen with EnableAutoReconnect:i:0, but it may be a coincidence.

Originally created by @itagagaki on GitHub (May 12, 2025). Original GitHub issue: https://github.com/1Remote/1Remote/issues/930 Originally assigned to: @VShawn on GitHub. Reproducibility is random. This did not happen with `EnableAutoReconnect:i:0`, but it may be a coincidence.
kerem 2026-03-01 17:22:28 +03:00
  • closed this issue
  • added the
    bug
    stale
    labels
Author
Owner

@VShawn commented on GitHub (May 12, 2025):

This did not happen with EnableAutoReconnect:i:0

there is no evidence to support this.

<!-- gh-comment-id:2872260328 --> @VShawn commented on GitHub (May 12, 2025): > This did not happen with EnableAutoReconnect:i:0 there is no evidence to support this.
Author
Owner

@itagagaki commented on GitHub (May 12, 2025):

This did not happen with EnableAutoReconnect:i:0

there is no evidence to support this.

I think you've said similar things before, but I don't understand why you think that.

<!-- gh-comment-id:2872353144 --> @itagagaki commented on GitHub (May 12, 2025): > > This did not happen with EnableAutoReconnect:i:0 > > there is no evidence to support this. I think you've said similar things before, but I don't understand why you think that.
Author
Owner

@itagagaki commented on GitHub (May 12, 2025):

Reproducibility is random.

This did not happen with EnableAutoReconnect:i:0, but it may be a coincidence.

Happened in this case as well.

<!-- gh-comment-id:2872533621 --> @itagagaki commented on GitHub (May 12, 2025): > Reproducibility is random. > > This did not happen with `EnableAutoReconnect:i:0`, but it may be a coincidence. Happened in this case as well.
Author
Owner

@itagagaki commented on GitHub (May 12, 2025):

This issue blocks #878

<!-- gh-comment-id:2872852466 --> @itagagaki commented on GitHub (May 12, 2025): This issue blocks #878
Author
Owner

@VShawn commented on GitHub (May 13, 2025):

It's also possible that this issue is related to switching to NET9. After the switch, I received a lot of feedback about programs freezing on the MS STORE, so I have now rolled back MS STORE to the old version.

<!-- gh-comment-id:2874932468 --> @VShawn commented on GitHub (May 13, 2025): It's also possible that this issue is related to `switching to NET9`. After the switch, I received a lot of feedback about programs freezing on the MS STORE, so I have now rolled back MS STORE to the old version.
Author
Owner

@VShawn commented on GitHub (May 14, 2025):

Perhaps it is related to the update of the AxMSTSCLib.dll dynamic library? Should I consider rolling it back?

The thought is If this issue has been occurring frequently since 1.2.0, it is likely related to the update in version 1.2.0, and the major change in version 1.2.0 for RDP is the update of the dll.

<!-- gh-comment-id:2879102773 --> @VShawn commented on GitHub (May 14, 2025): Perhaps it is related to the update of the AxMSTSCLib.dll dynamic library? Should I consider rolling it back? The thought is If this issue has been occurring frequently since 1.2.0, it is likely related to the update in version 1.2.0, and the major change in version 1.2.0 for RDP is the update of the dll.
Author
Owner

@itagagaki commented on GitHub (May 14, 2025):

The change in AxMSTSCLib.dll does not seem to be relevant.

The phenomena occurring are as follows:

  1. Double-click host A in the main window (host menu).
  2. Host A is unavailable, so alternative host B is connected.
  3. Make Host A available.
  4. Disconnect host B on the host side.
  5. 1Remote's reconnection logic begins to work.
  6. Connected to Host A, and Host A's desktop appears in the host view.
  7. In some cases, the tabable window freezes at this moment (but the app's periodic database update checks continue to run).
  8. Clicking the close button on the tab does not close it (but TabablzControl_OnPreviewMouseLeftButtonDown() is called). The close button on the tabable window closes the entire window.
  9. Closing the tabable window freezes the main window.

My guess is that the connection between the session and the window or tab is broken during reconnection and destrosys resources or objects that should not be destroyed.

<!-- gh-comment-id:2880440920 --> @itagagaki commented on GitHub (May 14, 2025): The change in AxMSTSCLib.dll does not seem to be relevant. The phenomena occurring are as follows: 1. Double-click host A in the main window (host menu). 2. Host A is unavailable, so alternative host B is connected. 3. Make Host A available. 4. Disconnect host B on the host side. 5. 1Remote's reconnection logic begins to work. 6. Connected to Host A, and Host A's desktop appears in the host view. 7. In some cases, the tabable window freezes at this moment (but the app's periodic database update checks continue to run). 8. Clicking the close button on the tab does not close it (but TabablzControl_OnPreviewMouseLeftButtonDown() is called). The close button on the tabable window closes the entire window. 9. Closing the tabable window freezes the main window. My guess is that the connection between the session and the window or tab is broken during reconnection and destrosys resources or objects that should not be destroyed.
Author
Owner

@VShawn commented on GitHub (May 15, 2025):

Well, it seems a bit different from what I thought. The reproduction logic is quite complex, kudos to you for being able to find it out.

then the crucial point lies on the auto reconnect logic, I considering a complete overhaul of this module.

<!-- gh-comment-id:2883481746 --> @VShawn commented on GitHub (May 15, 2025): Well, it seems a bit different from what I thought. The reproduction logic is quite complex, kudos to you for being able to find it out. then the crucial point lies on the auto reconnect logic, I considering a complete overhaul of this module.
Author
Owner

@itagagaki commented on GitHub (May 15, 2025):

then the crucial point lies on the auto reconnect logic, I considering a complete overhaul of this module.

I hope my fixes will help with that.
https://github.com/itagagaki/1Remote/tree/fix-rdp-reconnection

<!-- gh-comment-id:2883743165 --> @itagagaki commented on GitHub (May 15, 2025): > then the crucial point lies on the auto reconnect logic, I considering a complete overhaul of this module. I hope my fixes will help with that. https://github.com/itagagaki/1Remote/tree/fix-rdp-reconnection
Author
Owner

@VShawn commented on GitHub (May 17, 2025):

sorry, I've been quite busy with work these days and haven't had time to check GitHub.

May I ask if I can merge your branch directly, or would you prefer me to make modifications based on your work?

I have reviewed your code and it seems fine. However, 1Remote now may missing a button to cancel the reconnection for the user.

<!-- gh-comment-id:2887938141 --> @VShawn commented on GitHub (May 17, 2025): sorry, I've been quite busy with work these days and haven't had time to check GitHub. May I ask if I can merge your branch directly, or would you prefer me to make modifications based on your work? I have reviewed your code and it seems fine. However, 1Remote now may missing a button to cancel the reconnection for the user.
Author
Owner

@itagagaki commented on GitHub (May 17, 2025):

My branch above fixes #878
However, this bug has not yet been resolved, so it should not be merged.
I mentioned the branch to you because I think the code is necessary for analyzing this bug.
If you can fix this bug, then you can merge directly or I can submit a PR.
I will investigate this bug further, but I am busy too, so I don't know which of us will finish first.

1Remote now may missing a button to cancel the reconnection for the user.

The "Dismiss" button appears and works during the reconnect process.

<!-- gh-comment-id:2888025211 --> @itagagaki commented on GitHub (May 17, 2025): My branch above fixes #878 However, this bug has not yet been resolved, so it should not be merged. I mentioned the branch to you because I think the code is necessary for analyzing this bug. If you can fix this bug, then you can merge directly or I can submit a PR. I will investigate this bug further, but I am busy too, so I don't know which of us will finish first. > 1Remote now may missing a button to cancel the reconnection for the user. The "Dismiss" button appears and works during the reconnect process.
Author
Owner

@VShawn commented on GitHub (May 20, 2025):

After conducting several tests over the past few days, I have not encountered any freezing issues. It seems that my environment does not trigger this problem. Now I decided to halt my investigation into this matter until there are any new discoveries.

Here are the steps of my testing:

  1. Prepare three computers: A, B, C.
  2. Install 1Remote on A and create a new configuration: Set the main address point to B and the backup address to point to C.
  3. Disable the auto-reconnect feature by RDP (EnableAutoReconnect = false).
  4. Unplug the net cable from B, initiate the connection, should now connect to C.
  5. Reconnect the cable to B and unplug the cable from C. At this point, the RDP interface will stop refreshing for about 10 seconds, but the software will not become unresponsive.
  6. 1Remote will automatically reconnect to the B host.
  7. Unplug the network cable from B again, wait a few seconds, close the TAB window, and observe if the main window of 1Remote becomes unresponsive.
<!-- gh-comment-id:2894022603 --> @VShawn commented on GitHub (May 20, 2025): After conducting several tests over the past few days, I have not encountered any freezing issues. It seems that my environment does not trigger this problem. Now I decided to halt my investigation into this matter until there are any new discoveries. Here are the steps of my testing: 1. Prepare three computers: A, B, C. 2. Install 1Remote on A and create a new configuration: Set the main address point to B and the backup address to point to C. 3. Disable the auto-reconnect feature by RDP (EnableAutoReconnect = false). 4. Unplug the net cable from B, initiate the connection, should now connect to C. 5. Reconnect the cable to B and unplug the cable from C. At this point, the RDP interface will stop refreshing for about 10 seconds, but the software will not become unresponsive. 6. 1Remote will automatically reconnect to the B host. 7. Unplug the network cable from B again, wait a few seconds, close the TAB window, and observe if the main window of 1Remote becomes unresponsive.
Author
Owner

@github-actions[bot] commented on GitHub (Jun 20, 2025):

This issue is stale because it has been open for 30 days with no activity.

<!-- gh-comment-id:2989603579 --> @github-actions[bot] commented on GitHub (Jun 20, 2025): This issue is stale because it has been open for 30 days with no activity.
Author
Owner

@github-actions[bot] commented on GitHub (Jul 4, 2025):

This issue was closed because it has been inactive for 14 days since being marked as stale.

<!-- gh-comment-id:3034195326 --> @github-actions[bot] commented on GitHub (Jul 4, 2025): This issue was closed because it has been inactive for 14 days since being marked as stale.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/1Remote#2675
No description provided.