Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SyncTrayzor prevents ejecting USB drive #788

Open
ARF1 opened this issue Sep 21, 2023 · 0 comments
Open

SyncTrayzor prevents ejecting USB drive #788

ARF1 opened this issue Sep 21, 2023 · 0 comments

Comments

@ARF1
Copy link

ARF1 commented Sep 21, 2023

I have two "receive only"-folders on a removable USB disk. The folder watcher is disabled for both folders. However, even with the folder watcher disabled, it is impossible to safely remove the drive while SyncTrayzor is running.

To reproduce:

  1. Create a folder on an USB drive
  2. Set the folder as "receive only" (not essential to demonstrate the problem)
  3. Disable the folder watcher in SyncTrayzor for the folder on the USB drive
  4. Using the Windows 10 tray icon "Safely Remove Hardware and Eject Media", try to eject the USB drive with the Syncthing folder
  5. Error message titled "Problem Ejecting USB Composite Device": "This device is currently in use. Close any programs or windows that might be using the device and then try again."
  6. Terminate SyncTrayzor
  7. Try ejecting the USB drive again --> Success

I suspect that SyncTrayzor needs to use some Windows api to register to receive a notification when a user tries to eject hardware. SyncTrayzor can then close all its relevant file pointers, if the user tries to eject a drive that SyncTrayzor is using, to allow Windows to eject the drive.

@ARF1 ARF1 changed the title SyncTrayzor prevents ejecting removable drives SyncTrayzor prevents ejecting USB drive Sep 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant