mirror of
https://github.com/1Remote/1Remote.git
synced 2026-04-25 13:36:03 +03:00
[GH-ISSUE #841] An incorrect password in FTP will cause an exception to be thrown forever #3601
Labels
No labels
area-configuration
area-ct-app
area-ct-rdp
area-ct-remoteapp
area-ct-ssh
area-ct-vnc
area-launcher
area-list
area-tags
area-teamwork
bug
chore
dependencies
general-build/ci
general-performance
general-refactor
general-security
general-supportive
general-ux
meta-documentation
meta-enhancement
meta-enhancement
meta-feature
meta-help-wanted
meta-unknown-error
priority-hi
priority-low
pull-request
question
resolution-duplicate
resolution-invalid
resolution-wontfix
stale
task-put-off
task-still-considering
task-working-in-progress
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/1Remote#3601
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @itagagaki on GitHub (Jan 24, 2025).
Original GitHub issue: https://github.com/1Remote/1Remote/issues/841
Originally assigned to: @VShawn, @itagagaki on GitHub.
CPU usage remains elevated when authentication fails due to incorrect password in FTP.
An exception continues to be thrown when viewed in the debugger.
@itagagaki commented on GitHub (Jan 25, 2025):
In
vmFileTransmitHost.ShowFolder()github.com/1Remote/1Remote@0aaf606afb/Ui/View/Host/ProtocolHosts/VmFileTransmitHost.cs (L222C1-L265C75)If the exception is thrown after calling
Trans.ListDirectoryItems(), the catch block callsvmFileTransmitHost.ShowFolder()again recursively becauseCurrentPathis not yet set topath. It will catch another exception. So this goes as an infinite recursive call.What is the intention of calling
ShowFolder()again even after an exception is thrown?@VShawn commented on GitHub (Jan 26, 2025):
Uh, I don't remember why there was a recursive call in the exception; this code is quite old.
I guess the purpose:
when an error occurred during jumping from directory A to display directory B, thee code in the except block allows the UI to revert to displaying directory A. otherwise, due to the error in ls B, the UI would be blank.
Since I added a check
CurrentPath != pathbefore callingShowFolder(CurrentPath, showIoMessage: false);I believed that infinite recursive calls would not occur.Add a
_lastFailedPathfield to record the last failed, which can help avoid recursion.@itagagaki commented on GitHub (Jan 26, 2025):
I see. I have submitted a patch to solve everything.
@VShawn commented on GitHub (Jan 26, 2025):
good