libftdi Archives

Subject: ftdi_transfer_data_done busy loop

From: Omri Steiner <omri@xxxxxxxxxxxx>
To: libftdi@xxxxxxxxxxxxxxxxxxxxxxx
Date: Thu, 22 Aug 2019 11:22:35 +0300
Hey,
It seems that both ftdi_transfer_data_done and ftdi_transfer_data_cancel call libusb_handle_events_timeout_completed with zero timeval, with the intention of indefinitely blocking (it even states so in ftdi_transfer_data_cancel's documentation).
However, in practice, libusb_handle_events_timeout_completed with zero timeval just acts as a non-blocking function, which means both of these functions actually busy-wait instead of polling indefinitely.
Am I missing something?
Shall I propose a patch?

--- Omri


libftdi - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx


Current Thread