Re: [Patch size_t V3 00/19] use size_t
From: Junio C Hamano <hidden>
Date: 2017-08-16 21:34:07
Martin Koegler [off-list ref] writes:
From: Martin Koegler <redacted> This patchset is for next [24db08a6e8fed761d3bace7f2d5997806e20b9f7]. Its a complete collection of all patches. Some errors were fixed and it sticks with off_t for length in (pack) files. Object sizes are handled as size_t.
Thanks for an update. I am in the middle of today's integration cycle already, so I won't be able to apply them to my tree, see how it interacts with various other topics, and if I can rebase it off of 'next' as of yesterday (I am hoping that I can update 'next' with a few new topics today) to give it a more appropriate base, at least until late this evening. Making it "a complete collection" is very much appreciated, as I can forget about random pieces that were picked up so far. I haven't looked at the patch text, but I agree that the use of off_t for something that could become a location in a file and use of size_t for objects that we handle in-core would be a good place to start (and probably a good place to stop, at least for now).
Martin Koegler (19): delta: fix enconding size larger than an "uint" can hold Convert size datatype to size_t Convert zlib.c to size_t delta: Fix offset overflows Convert sha1_file.c to size_t Use size_t for sha1 Convert parse_X_buffer to size_t Convert fsck.c & commit.c to size_t Convert cache functions to size_t Add overflow check to get_delta_hdr_size Use size_t for config parsing Convert pack-objects to size_t Convert index-pack to size_t Convert unpack-objects to size_t Convert archive functions to size_t Convert various things to size_t Convert ref-filter to size_t Convert tree-walk to size_t Convert xdiff-interface to size_t
Usually we try to make these more like
delta: fix enconding size larger than an "uint" can hold
pack-objects: use size_t for sizes, not ulong
tree-walk: use size_t for sizes, not ulong
or (perhaps even better for this series)
size_t: convert pack-objects away from ulong
size_t: convert tree-walk away from ulong
...
so that readers of "git shortlog --no-merges" can visually spot
a group of patches that are around the same theme.
95 files changed, 525 insertions(+), 489 deletions(-)
That's a lot of changes. Let's see how well it goes. Thanks.