summaryrefslogtreecommitdiff
path: root/t/unit-tests
diff options
context:
space:
mode:
Diffstat (limited to 't/unit-tests')
-rw-r--r--t/unit-tests/t-reftable-readwrite.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/t/unit-tests/t-reftable-readwrite.c b/t/unit-tests/t-reftable-readwrite.c
index 3fba888cda..4c49129439 100644
--- a/t/unit-tests/t-reftable-readwrite.c
+++ b/t/unit-tests/t-reftable-readwrite.c
@@ -23,22 +23,22 @@ static void t_buffer(void)
{
struct reftable_buf buf = REFTABLE_BUF_INIT;
struct reftable_block_source source = { 0 };
- struct reftable_block out = { 0 };
+ struct reftable_block_data out = { 0 };
int n;
uint8_t in[] = "hello";
check(!reftable_buf_add(&buf, in, sizeof(in)));
block_source_from_buf(&source, &buf);
check_int(block_source_size(&source), ==, 6);
- n = block_source_read_block(&source, &out, 0, sizeof(in));
+ n = block_source_read_data(&source, &out, 0, sizeof(in));
check_int(n, ==, sizeof(in));
check(!memcmp(in, out.data, n));
- block_source_return_block(&out);
+ block_source_release_data(&out);
- n = block_source_read_block(&source, &out, 1, 2);
+ n = block_source_read_data(&source, &out, 1, 2);
check_int(n, ==, 2);
check(!memcmp(out.data, "el", 2));
- block_source_return_block(&out);
+ block_source_release_data(&out);
block_source_close(&source);
reftable_buf_release(&buf);
}