🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: linux.kernel.git
1 messages
1 total messages Started by Aniket Gupta Tue, 20 Oct 2026 16:54
Re: [PATCH] reftable/record: bound an object record's offset count by its length
#928
Author: Aniket Gupta
Date: Tue, 20 Oct 2026 16:54
18 lines
11215 bytes
Hi Matthew,

> By fixing that one function we also implicitly fix all the other
> callers that may currently be wrong.

I tried Patrick's change on a 32 bit build and it works for
REFTABLE_ALLOC_ARRAY. However REFTABLE_CALLOC_ARRAY goes straight to
reftable_calloc() with a size_t and gets truncated. I think no one
passes a 64 bit count to it so nothing breaks but maybe worth a
mention in the commit message?

Also the new test passes because of the count > in.len check. If
that check goes away in v2 I think it might need a different test
since on 64 bit nothing truncates. Maybe we can test
reftable_alloc_size() directly?

Aniket
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads