From 55fbf820808166d49fa51ca6de9a3ddeaaeeec88 Mon Sep 17 00:00:00 2001 From: Remi Tricot-Le Breton Date: Thu, 16 Nov 2023 17:38:11 +0100 Subject: [PATCH] MINOR: shctx: Set last_append to NULL when reserving block in hot list Ensure that the last_append pointer is always set to NULL on first block of rows reserved by the subsystems using the shctx (cache for instance). This pointer will be used directly in shctx_row_data_append instead of the 'from' param which will simplify its uses. --- src/shctx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/shctx.c b/src/shctx.c index d114d469f..862adb68b 100644 --- a/src/shctx.c +++ b/src/shctx.c @@ -114,6 +114,7 @@ struct shared_block *shctx_row_reserve_hot(struct shared_context *shctx, ret->block_count = freed; ret->refcount = 1; ret->last_reserved = block; + ret->last_append = NULL; enough = 1; break; }