Clear streaming flag if we didn't resubmit a transfer.
If result < 0 here, libusb_submit_transfer returned an error, so we need to shut down. If !resubmit, then cancel_transfers() was already called by one of the stop or close functions, so streaming is already false.
This commit is contained in:
@ -1754,6 +1754,7 @@ static void LIBUSB_CALL hackrf_libusb_transfer_callback(struct libusb_transfer*
|
||||
|
||||
if (!resubmit || result < 0) {
|
||||
transfer_finished(device, usb_transfer);
|
||||
device->streaming = false;
|
||||
}
|
||||
} else {
|
||||
transfer_finished(device, usb_transfer);
|
||||
|
Reference in New Issue
Block a user