From: Simon Richter Date: Sat, 17 Oct 2026 00:18:41 GMT Subject: Re: [PATCH 2/5] http: use `size_t` for byte position in fwrite_sha1_file Message-ID: <395b47c0-6dc7-4a1b-b547-e5e68e7356f5@hogyros.de> In-Reply-To: Hi, On 10/16/26 23:30, Junio C Hamano wrote: > I agree that changing the type of posn from int to size_t is the > right move. It is a position in a file that is being read as binary data[1], so off_t would be the best choice I think. That is still signed, but it can't overflow, because opening large files requires O_LARGEFILE, which is available only if large file support is enabled, which conveniently makes sure that off_t is 64 bit. Simon [1] to make a distinction from the use case for fpos_t