]> sigrok.org Git - libsigrok.git/blobdiff - include/libsigrok/proto.h
resource: Replace ssize_t with gssize to avoid unistd.h
[libsigrok.git] / include / libsigrok / proto.h
index ea9d477946fd7ae74a963f77e1dc89dd3c906a0e..6ae3be8f856d2567fe58755d7717f7141c8a3410 100644 (file)
@@ -20,8 +20,6 @@
 #ifndef LIBSIGROK_PROTO_H
 #define LIBSIGROK_PROTO_H
 
-#include <unistd.h>
-
 /**
  * @file
  *
@@ -208,7 +206,7 @@ typedef int (*sr_resource_open_callback)(struct sr_resource *res,
                const char *name, void *cb_data);
 typedef int (*sr_resource_close_callback)(struct sr_resource *res,
                void *cb_data);
-typedef ssize_t (*sr_resource_read_callback)(const struct sr_resource *res,
+typedef gssize (*sr_resource_read_callback)(const struct sr_resource *res,
                void *buf, size_t count, void *cb_data);
 
 SR_API int sr_resource_set_hooks(struct sr_context *ctx,