manson-hcs-3xxx: Fix blocking serial write timeout.
This fixes bug #437.
This commit is contained in:
parent
32c45845f7
commit
896e1a45e0
|
@ -44,7 +44,8 @@ SR_PRIV int hcs_send_cmd(struct sr_serial_dev_inst *serial, const char *cmd, ...
|
||||||
sr_dbg("Sending '%s'.", cmd_esc);
|
sr_dbg("Sending '%s'.", cmd_esc);
|
||||||
g_free(cmd_esc);
|
g_free(cmd_esc);
|
||||||
|
|
||||||
if ((ret = serial_write_blocking(serial, cmdbuf, strlen(cmdbuf), 0)) < 0) {
|
if ((ret = serial_write_blocking(serial, cmdbuf, strlen(cmdbuf),
|
||||||
|
serial_timeout(serial, strlen(cmdbuf)))) < 0) {
|
||||||
sr_err("Error sending command: %d.", ret);
|
sr_err("Error sending command: %d.", ret);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue