Find out which process has an exclusive lock on a USB device handle

后端 未结 4 1993
死守一世寂寞
死守一世寂寞 2021-01-12 11:02

I have a library that reads/writes to a USB-device using CreateFile() API. The device happens to implement the HID-device profile, such that it\'s compatible with Microsoft\

4条回答
  •  遥遥无期
    2021-01-12 11:51

    Have you tried the tool called handle from sysinternals?

    Anyway, neither windows does this (display the name of the application that locked the device): when you try to eject an USB device, Windows just says that the device is currently in use and cannot be remove right now.

提交回复
热议问题