From 9052b1be9e50cf04fdd682834e69b6c1839335e5 Mon Sep 17 00:00:00 2001 From: dongwlin Date: Wed, 11 Dec 2024 11:42:08 +0800 Subject: [PATCH] fix: wait find device --- source/cli/device.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/cli/device.cpp b/source/cli/device.cpp index 2338e97..216934e 100644 --- a/source/cli/device.cpp +++ b/source/cli/device.cpp @@ -15,7 +15,8 @@ bool default_device_init(DeviceConfig& device) MaaSize scanning_devices() { std::cout << "Scanning for Devices..." << std::endl; - auto device_size = MaaToolkitPostFindDevice(); + MaaToolkitPostFindDevice(); + auto device_size = MaaToolkitWaitForFindDeviceToComplete(); if (device_size == 0) { std::cout << "No Devices Found" << std::endl; return 0;