From 5e127578f0c68ee9baa67d867d75c6a714bd1176 Mon Sep 17 00:00:00 2001 From: Rob Austein Date: Tue, 27 Sep 2016 12:55:42 -0400 Subject: Add hal_ks_index_replace(). --- hal_internal.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'hal_internal.h') diff --git a/hal_internal.h b/hal_internal.h index 2318748..ef0d763 100644 --- a/hal_internal.h +++ b/hal_internal.h @@ -645,6 +645,16 @@ extern hal_error_t hal_ks_index_delete(hal_ks_index_t *ksi, const hal_uuid_t * const name, unsigned *blockno); +/* + * Replace a key block with a new one, return new block number. + * Name of block does not change. This is an optimization of + * a delete immediately followed by an add for the same name. + */ + +extern hal_error_t hal_ks_index_replace(hal_ks_index_t *ksi, + const hal_uuid_t * const name, + unsigned *blockno); + /* * RPC lowest-level send and receive routines. These are blocking, and * transport-specific (sockets, USB). -- cgit v1.2.3