<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/midx.c, branch v2.20.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.20.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.20.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2018-11-29T06:45:31Z</updated>
<entry>
<title>i18n: fix small typos</title>
<updated>2018-11-29T06:45:31Z</updated>
<author>
<name>Jean-Noël Avila</name>
<email>jn.avila@free.fr</email>
</author>
<published>2018-11-28T21:43:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=d355e46a15943554b917f3198f2c6dc78011dd4c'/>
<id>urn:sha1:d355e46a15943554b917f3198f2c6dc78011dd4c</id>
<content type='text'>
Translating the new strings introduced for v2.20 showed some typos.

Signed-off-by: Jean-Noël Avila &lt;jn.avila@free.fr&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/unused-parameter-fixes'</title>
<updated>2018-11-18T09:23:53Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-11-18T09:23:53Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=ab96f28ba4deb71ff64b31bd63cee96314db7112'/>
<id>urn:sha1:ab96f28ba4deb71ff64b31bd63cee96314db7112</id>
<content type='text'>
Various functions have been audited for "-Wunused-parameter" warnings
and bugs in them got fixed.

* jk/unused-parameter-fixes:
  midx: double-check large object write loop
  assert NOARG/NONEG behavior of parse-options callbacks
  parse-options: drop OPT_DATE()
  apply: return -1 from option callback instead of calling exit(1)
  cat-file: report an error on multiple --batch options
  tag: mark "--message" option with NONEG
  show-branch: mark --reflog option as NONEG
  format-patch: mark "--no-numbered" option with NONEG
  status: mark --find-renames option with NONEG
  cat-file: mark batch options with NONEG
  pack-objects: mark index-version option as NONEG
  ls-files: mark exclude options as NONEG
  am: handle --no-patch-format option
  apply: mark include/exclude options as NONEG
</content>
</entry>
<entry>
<title>Merge branch 'ds/test-multi-pack-index'</title>
<updated>2018-11-13T13:37:19Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-11-13T13:37:19Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=5fb9263295b425c7acfde66c8abe5d53fa55d2c3'/>
<id>urn:sha1:5fb9263295b425c7acfde66c8abe5d53fa55d2c3</id>
<content type='text'>
Tests for the recently introduced multi-pack index machinery.

* ds/test-multi-pack-index:
  packfile: close multi-pack-index in close_all_packs
  multi-pack-index: define GIT_TEST_MULTI_PACK_INDEX
  midx: close multi-pack-index on repack
  midx: fix broken free() in close_midx()
</content>
</entry>
<entry>
<title>midx: double-check large object write loop</title>
<updated>2018-11-06T03:57:08Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2018-11-04T02:27:46Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=61b0fcbb64d00d52290d433c1e754c01740b3d19'/>
<id>urn:sha1:61b0fcbb64d00d52290d433c1e754c01740b3d19</id>
<content type='text'>
The write_midx_large_offsets() function takes an array of object
entries, the number of entries in the array (nr_objects), and the number
of entries with large offsets (nr_large_offset). But we never actually
use nr_objects; instead we keep walking down the array and counting down
nr_large_offset until we've seen all of the large entries.

This is correct, but we can be a bit more defensive. If there were ever
a mismatch between nr_large_offset and the actual set of large-offset
objects, we'd walk off the end of the array.

Since we know the size of the array, we can use nr_objects to make sure
we don't walk too far.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Reviewed-by: Derrick Stolee &lt;dstolee@microsoft.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>multi-pack-index: define GIT_TEST_MULTI_PACK_INDEX</title>
<updated>2018-10-22T01:42:46Z</updated>
<author>
<name>Derrick Stolee</name>
<email>dstolee@microsoft.com</email>
</author>
<published>2018-10-12T17:34:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=0465a50506023df0932fe0534fe6ac6712c0d854'/>
<id>urn:sha1:0465a50506023df0932fe0534fe6ac6712c0d854</id>
<content type='text'>
The multi-pack-index feature is tested in isolation by
t5319-multi-pack-index.sh, but there are many more interesting
scenarios in the test suite surrounding pack-file data shapes
and interactions. Since the multi-pack-index is an optional
data structure, it does not make sense to include it by default
in those tests.

Instead, add a new GIT_TEST_MULTI_PACK_INDEX environment variable
that enables core.multiPackIndex and writes a multi-pack-index
after each 'git repack' command. This adds extra test coverage
when needed.

There are a few spots in the test suite that need to react to this
change:

* t5319-multi-pack-index.sh: there is a test that checks that
  'git repack' deletes the multi-pack-index. Disable the environment
  variable to ensure this still happens.

* t5310-pack-bitmaps.sh: One test moves a pack-file from the object
  directory to an alternate. This breaks the multi-pack-index, so
  delete the multi-pack-index at this point, if it exists.

* t9300-fast-import.sh: One test verifies the number of files in
  the .git/objects/pack directory is exactly 8. Exclude the
  multi-pack-index from this count so it is still 8 in all cases.

Signed-off-by: Derrick Stolee &lt;dstolee@microsoft.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>midx: close multi-pack-index on repack</title>
<updated>2018-10-22T01:42:46Z</updated>
<author>
<name>Derrick Stolee</name>
<email>dstolee@microsoft.com</email>
</author>
<published>2018-10-12T17:34:19Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=1dcd9f2043a38f0c9684d47c71b9e383942660ac'/>
<id>urn:sha1:1dcd9f2043a38f0c9684d47c71b9e383942660ac</id>
<content type='text'>
When repacking, we may remove pack-files. This invalidates the
multi-pack-index (if it exists). Previously, we removed the
multi-pack-index file before removing any pack-file. In some cases,
the repack command may load the multi-pack-index into memory. This
may lead to later in-memory references to the non-existent pack-
files.

Signed-off-by: Derrick Stolee &lt;dstolee@microsoft.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>multi-pack-index: avoid dead store for struct progress</title>
<updated>2018-10-19T02:16:53Z</updated>
<author>
<name>Carlo Marcelo Arenas Belón</name>
<email>carenas@gmail.com</email>
</author>
<published>2018-10-18T18:59:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=17eeb067dade419246c73a97cb86535723cee473'/>
<id>urn:sha1:17eeb067dade419246c73a97cb86535723cee473</id>
<content type='text'>
it is initialized unconditionally by a call to start_progress
below.

Signed-off-by: Carlo Marcelo Arenas Belón &lt;carenas@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/oideq-hasheq-cleanup'</title>
<updated>2018-10-16T07:16:08Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-10-16T07:16:07Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=ee56992a8792cd5e67029e71f3c75d7ce662ae6d'/>
<id>urn:sha1:ee56992a8792cd5e67029e71f3c75d7ce662ae6d</id>
<content type='text'>
Code clean-up.

* jk/oideq-hasheq-cleanup:
  more oideq/hasheq conversions
</content>
</entry>
<entry>
<title>midx: fix broken free() in close_midx()</title>
<updated>2018-10-09T09:04:15Z</updated>
<author>
<name>Derrick Stolee</name>
<email>dstolee@microsoft.com</email>
</author>
<published>2018-10-08T15:17:03Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=0ce4ff942125eabed3df694dc27922bec8177624'/>
<id>urn:sha1:0ce4ff942125eabed3df694dc27922bec8177624</id>
<content type='text'>
When closing a multi-pack-index, we intend to close each pack-file
and free the struct packed_git that represents it. However, this
line was previously freeing the array of pointers, not the
pointer itself. This leads to a double-free issue.

Signed-off-by: Derrick Stolee &lt;dstolee@microsoft.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>more oideq/hasheq conversions</title>
<updated>2018-10-04T10:42:48Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2018-10-02T21:19:21Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=e43d2dcce1db256e95b90f89e06d62834a1d361c'/>
<id>urn:sha1:e43d2dcce1db256e95b90f89e06d62834a1d361c</id>
<content type='text'>
We added faster equality-comparison functions for hashes in
14438c4497 (introduce hasheq() and oideq(), 2018-08-28). A
few topics were in-flight at the time, and can now be
converted. This covers all spots found by "make coccicheck"
in master (the coccicheck results were tweaked by hand for
style).

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
