Increase timeout for Mares devices

Linus came diagnosed the issue and came up with the patch, Jef suggested to use
a 3 second timeout instead of 5.

Reported-by: Tiberio Alunni <tiberio.alunni@gmail.com>
Suggested-by: Linus Torvalds <torvalds@linux-foundation.org>
Suggested-by: Jef Driesen <jef@libdivecomputer.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2019-12-10 09:46:57 -08:00
parent 426a39fc73
commit c9dd81852e

View File

@ -482,8 +482,8 @@ mares_iconhd_device_open (dc_device_t **out, dc_context_t *context, dc_iostream_
goto error_free; goto error_free;
} }
// Set the timeout for receiving data (1000 ms). // Set the timeout for receiving data (3 sec = 3000 ms).
status = dc_iostream_set_timeout (device->iostream, 1000); status = dc_iostream_set_timeout (device->iostream, 3000);
if (status != DC_STATUS_SUCCESS) { if (status != DC_STATUS_SUCCESS) {
ERROR (context, "Failed to set the timeout."); ERROR (context, "Failed to set the timeout.");
goto error_free; goto error_free;