diff --git a/api/liboni/oni.c b/api/liboni/oni.c index 6934054..9716315 100644 --- a/api/liboni/oni.c +++ b/api/liboni/oni.c @@ -688,7 +688,7 @@ int oni_read_frame(const oni_ctx ctx, oni_frame_t **frame) total_size += rsize; // Direct frame data's view into the pre-collected buffer - assert(ctx->shared_rbuf->read_pos + rsize <= ctx->shared_rbuf->end_pos + assert(ctx->shared_rbuf->read_pos + rsize <= ctx->shared_rbuf->end_pos && "Attempted to read past buffer end"); iframe->private.f.data = ctx->shared_rbuf->read_pos; ctx->shared_rbuf->read_pos += rsize; @@ -1225,7 +1225,7 @@ static inline int _oni_read_config(oni_ctx ctx, oni_config_t reg, oni_reg_val_t static int _oni_ensure_read_buffer(oni_ctx ctx) { - // NB: This function can only be called if the device table has been + // NB: This function can only be called if the device table has been // populated and contains devices that produce data. if (ctx->max_read_frame_size == 0) return ONI_EINVALARG; diff --git a/api/liboni/oni.h b/api/liboni/oni.h index 8d910b5..972ff4b 100644 --- a/api/liboni/oni.h +++ b/api/liboni/oni.h @@ -51,7 +51,7 @@ typedef struct { const oni_fifo_time_t time; // Frame time (ACQCLKHZ) const oni_fifo_dat_t dev_idx; // Device index that produced or accepts the frame const oni_fifo_dat_t data_sz; // Size in bytes of data buffer - char *data; // Raw data block + void *data; // Raw data block } oni_frame_t;