添加限制条件不能再次今次read_int 线程

This commit is contained in:
13038267101 2023-04-28 15:21:36 +08:00
parent 60f0065af8
commit d27c3c1149
1 changed files with 9 additions and 6 deletions

View File

@ -347,12 +347,15 @@ void hg_scanner::thread_devslock_handle(void)
}
void hg_scanner::thread_read_int(void)
{
wait_read_int.wait();
is_read_int = true;
notify_ui_working_status(STATU_DESC_SCANNER_ERR_DEVICE_DEVS_BOOTING, SANE_EVENT_STATUS, status_);
discard_all_images();
is_read_int = false;
notify_ui_working_status(STATU_DESC_SCANNER_ERR_DEVICE_DEVS_START_SUCCES, SANE_EVENT_STATUS, status_);
if (run_)
{
wait_read_int.wait();
is_read_int = true;
notify_ui_working_status(STATU_DESC_SCANNER_ERR_DEVICE_DEVS_BOOTING, SANE_EVENT_STATUS, status_);
discard_all_images();
is_read_int = false;
notify_ui_working_status(STATU_DESC_SCANNER_ERR_DEVICE_DEVS_START_SUCCES, SANE_EVENT_STATUS, status_);
}
}
void hg_scanner::thread_handle_usb(void)
{