[Windows] Pasting multiple files through clipboard becomes increasingly slow and eventually fails
Bug Description
When copying files from a remote Windows computer to the local Windows computer through RustDesk using Ctrl+C / Ctrl+V, the issue appears to be related to the number of files, rather than the total amount of data being transferred. Ctrl+C on the remote computer works normally. The problem occurs after pressing Ctrl+V on the local computer. My tests:
- 1 file, 32 MB: pastes normally with no noticeable delay.
- 45 small files: the paste operation takes several seconds to respond/start, but eventually works.
- 50 small files, only 8.30 MB total: the paste operation fails. Windows shows the busy/hourglass cursor, but the transfer does not start and no files are pasted. Therefore, a single 32 MB file transfers immediately, while 50 files totaling only 8.30 MB fail to start. The delay also appears to increase progressively as more files are selected. This behavior is reproducible on my setup.
How to Reproduce
- Connect to a Windows computer using RustDesk.
- On the remote computer, select multiple small files in Windows Explorer.
- Press Ctrl+C.
- On the local computer, open a destination folder and press Ctrl+V.
- With a small number of files, the paste works normally.
- Increase the number of selected files.
- At around 45 files, there is a noticeable delay before the paste/transfer starts.
- With 50 small files (8.30 MB total in my test), the paste operation fails to start.
- As a comparison, copying and pasting a single 32 MB file works immediately without noticeable delay.
Expected Behavior
Pasting multiple files from the remote computer to the local computer should start normally regardless of the number of files selected.
A selection of many small files should not introduce a long delay before the transfer starts or cause the paste operation to fail, especially when the total amount of data is very small.
For comparison, a single 32 MB file pastes immediately in my tests, while 50 small files totaling only 8.30 MB fail to start.
Operating system(s) on local (controlling) side and remote (controlled) side
Windows 11 -> Windows 10
RustDesk Version(s) on local (controlling) side and remote (controlled) side
1.4.9 -> 1.4.9
Screenshots
There is no error message displayed.
The issue is visible as a long busy/wait cursor after pressing Ctrl+V. With 50 files, the file transfer never starts.
A video demonstrating the behavior is attached.
Additional Context
I am using a self-hosted RustDesk server (hbbs/hbbr).
The issue is reproducible and appears to scale with the number of selected files rather than the total transfer size.
Current test results:
- 1 file / 32 MB: pastes immediately, no noticeable delay.
- 45 small files: pastes successfully, but there is a significant delay before the transfer starts.
- 50 small files / 8.30 MB total: paste fails to start completely.
Ctrl+C on the remote computer does not appear to be delayed. The problem occurs on the local computer after pressing Ctrl+V.
No error message is displayed when the operation fails.
Source: rustdesk/rustdesk