Re: [PATCH 04/10] reftable: convert from `strbuf` to `reftable_buf`
From: karthik nayak <hidden>
Date: 2024-10-11 12:13:01
Attachments
- signature.asc [application/pgp-signature] 690 bytes
From: karthik nayak <hidden>
Date: 2024-10-11 12:13:01
Patrick Steinhardt [off-list ref] writes:
Convert the reftable library to use the `reftable_buf` interface instead of the `strbuf` interface. This is a mechanical change via sed(1) and does not yet handle allocation failures. These will be addressed in subsequent commits.
Nit: Would be nice to list the sed command used here, so reviewers can review that instead. [snip]
diff --git a/reftable/basics.h b/reftable/basics.h index 4cf3f0e7593..ac3100417ec 100644 --- a/reftable/basics.h +++ b/reftable/basics.h@@ -104,8 +104,7 @@ char *reftable_strdup(const char *str); #endif /* Find the longest shared prefix size of `a` and `b` */ -struct strbuf;
I guess this is the only manual part of this commit, would be nice to mention this in the message.
-int common_prefix_size(struct strbuf *a, struct strbuf *b); +int common_prefix_size(struct reftable_buf *a, struct reftable_buf *b); int hash_size(uint32_t id);
[snip]