Kill adb daemon in OTG mode on Windows
On Windows, it is not possible to open a USB device from several process, so HID events may only work if no adb daemon is running. PR #3011 <https://github.com/Genymobile/scrcpy/pull/3011>
This commit is contained in:
@@ -204,6 +204,14 @@ sc_adb_start_server(struct sc_intr *intr, unsigned flags) {
|
||||
return process_check_success_intr(intr, pid, "adb start-server", flags);
|
||||
}
|
||||
|
||||
bool
|
||||
sc_adb_kill_server(struct sc_intr *intr, unsigned flags) {
|
||||
const char *const argv[] = SC_ADB_COMMAND("kill-server");
|
||||
|
||||
sc_pid pid = sc_adb_execute(argv, flags);
|
||||
return process_check_success_intr(intr, pid, "adb kill-server", flags);
|
||||
}
|
||||
|
||||
bool
|
||||
sc_adb_forward(struct sc_intr *intr, const char *serial, uint16_t local_port,
|
||||
const char *device_socket_name, unsigned flags) {
|
||||
|
||||
Reference in New Issue
Block a user