From c07be5da381a67b8c4ffd55866116b73bcaba06c Mon Sep 17 00:00:00 2001 From: Gediminas Jakutis Date: Mon, 29 Mar 2021 23:57:53 +0300 Subject: trivial fixes. Signed-off-by: Gediminas Jakutis --- src/stream.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/stream.c') diff --git a/src/stream.c b/src/stream.c index 48f7e4c..75f2c04 100644 --- a/src/stream.c +++ b/src/stream.c @@ -107,7 +107,7 @@ struct entry_l *file_get_array(struct stream * const in, struct entry_l * const if (in->index < in->n) { do { - try(0 > (bytes_read = pread(in->fd, &ent, sizeof(ent), in->index * in->settings->stride)), err, NULL, "Writing to stream failed with %i", errno); + try(0 > (bytes_read = pread(in->fd, &ent, sizeof(ent), in->index * in->settings->stride)), err, NULL, "Reading from stream failed with %i", errno); } while (bytes_read != sizeof(ent)); ++in->index; @@ -127,7 +127,7 @@ struct entry_l *file_get_list(struct stream * const in, struct entry_l * const s if (in->cnode) { do { - try(0 > (bytes_read = pread(in->fd, &ent, sizeof(ent), in->cnode->file_offset)), err, NULL, "Writing to stream failed with %i", errno); + try(0 > (bytes_read = pread(in->fd, &ent, sizeof(ent), in->cnode->file_offset)), err, NULL, "Reading from stream failed with %i", errno); } while (bytes_read != sizeof(ent)); store->val = ent.val; -- cgit v1.2.3