#include <libudev.h>
#include <sigrok.h>
#include <arpa/inet.h>
+#include <sigrok-internal.h>
#include "config.h"
#include "link-mso19.h"
w = 0;
while (w < s) {
- ret = write(fd, buf + w, s - w);
+ ret = serial_write(fd, buf + w, s - w);
if (ret < 0) {
ret = SIGROK_ERR;
goto free;
return ret;
buf[0] = 0;
- if (read(sdi->serial->fd, buf, 1) != 1) /* FIXME: Need timeout */
+ if (serial_read(sdi->serial->fd, buf, 1) != 1) /* FIXME: Need timeout */
ret = SIGROK_ERR;
*info = buf[0];
revents = revents;
- s = read(fd, in, sizeof(in));
+ s = serial_read(fd, in, sizeof(in));
if (s <= 0)
return FALSE;