]> git.ipfire.org Git - thirdparty/git.git/commit
reftable/system: add abstraction to mmap files
authorPatrick Steinhardt <ps@pks.im>
Thu, 2 Apr 2026 07:31:18 +0000 (09:31 +0200)
committerJunio C Hamano <gitster@pobox.com>
Thu, 2 Apr 2026 17:45:44 +0000 (10:45 -0700)
commit87e4eee3f94ec261a92a76d06261b227b00de461
tree4e2baee0836ac16f4813ba107630a785683b3d55
parentcb0882de1979522b2fc3dc4c3064b0ad21d50b06
reftable/system: add abstraction to mmap files

In our codebase we have a couple of wrappers around mmap(3p) that allow
us to reimplement the syscall on platforms that don't have it natively,
like for example Windows. Other projects that embed the reftable library
may have a different infra though to hook up mmap wrappers, but these
are currently hard to integrate.

Provide the infrastructure to let projects easily define the mmap
interface with a custom struct and custom functions.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
reftable/blocksource.c
reftable/system.c
reftable/system.h