<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/cache.h, branch v2.6.4</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://www.git.shady.money/git/atom?h=v2.6.4</id>
<link rel='self' href='https://www.git.shady.money/git/atom?h=v2.6.4'/>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/'/>
<updated>2015-12-08T22:05:03Z</updated>
<entry>
<title>Merge branch 'ad/sha1-update-chunked' into maint</title>
<updated>2015-12-08T22:05:03Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-12-08T22:05:03Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=b5d2d8eef0ad08022a3f635c0bc292eb2cc5aefc'/>
<id>urn:sha1:b5d2d8eef0ad08022a3f635c0bc292eb2cc5aefc</id>
<content type='text'>
Apple's common crypto implementation of SHA1_Update() does not take
more than 4GB at a time, and we now have a compile-time workaround
for it.

* ad/sha1-update-chunked:
  sha1: allow limiting the size of the data passed to SHA1_Update()
  sha1: provide another level of indirection for the SHA-1 functions
</content>
</entry>
<entry>
<title>Merge branch 'dk/gc-idx-wo-pack' into maint</title>
<updated>2015-12-04T19:33:08Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-12-04T19:33:07Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=b50ceab48f46a74571ee2a89048563dd5d3322b9'/>
<id>urn:sha1:b50ceab48f46a74571ee2a89048563dd5d3322b9</id>
<content type='text'>
Having a leftover .idx file without corresponding .pack file in
the repository hurts performance; "git gc" learned to prune them.

We may want to do the same for .bitmap (and notice but not prune
.keep) without corresponding .pack, but that can be a separate
topic.

* dk/gc-idx-wo-pack:
  gc: remove garbage .idx files from pack dir
  t5304: test cleaning pack garbage
  prepare_packed_git(): refactor garbage reporting in pack directory
</content>
</entry>
<entry>
<title>sha1: allow limiting the size of the data passed to SHA1_Update()</title>
<updated>2015-11-05T18:35:11Z</updated>
<author>
<name>Atousa Pahlevan Duprat</name>
<email>apahlevan@ieee.org</email>
</author>
<published>2015-11-05T06:38:42Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=001fd7a90b5851f62e700510729a5e09706f9b63'/>
<id>urn:sha1:001fd7a90b5851f62e700510729a5e09706f9b63</id>
<content type='text'>
Using the previous commit's inredirection mechanism for SHA1,
support a chunked implementation of SHA1_Update() that limits the
amount of data in the chunk passed to SHA1_Update().

This is enabled by using the Makefile variable SHA1_MAX_BLOCK_SIZE
to specify chunk size.  When using Apple's CommonCrypto library this
is set to 1GiB (the implementation cannot handle more 4GiB).

Signed-off-by: Atousa Pahlevan Duprat &lt;apahlevan@ieee.org&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>sha1: provide another level of indirection for the SHA-1 functions</title>
<updated>2015-11-05T18:35:11Z</updated>
<author>
<name>Atousa Pahlevan Duprat</name>
<email>apahlevan@ieee.org</email>
</author>
<published>2015-11-05T06:38:41Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=3bc72fde3f35b988c902abf5a0bc027f2e54d0c1'/>
<id>urn:sha1:3bc72fde3f35b988c902abf5a0bc027f2e54d0c1</id>
<content type='text'>
The git source uses git_SHA1_Update() and friends to call into the
code that computes the hashes.  Traditionally, we used to map these
directly to underlying implementation of the SHA-1 hash (e.g.
SHA1_Update() from OpenSSL or blk_SHA1_Update() from block-sha1/).

This arrangement however makes it hard to tweak behaviour of the
underlying implementation without fully replacing.  If we want to
introduce a tweaked_SHA1_Update() wrapper to implement the "Update"
in a slightly different way, for example, the implementation of the
wrapper still would want to call into the underlying implementation,
but tweaked_SHA1_Update() cannot call git_SHA1_Update() to get to
the underlying implementation (often but not always SHA1_Update()).

Add another level of indirection that maps platform_SHA1_Update()
and friends to their underlying implementations, and by default make
git_SHA1_Update() and friends map to platform_SHA1_* functions.

Doing it this way will later allow us to map git_SHA1_Update() to
tweaked_SHA1_Update(), and the latter can use platform_SHA1_Update()
in its implementation.

Signed-off-by: Atousa Pahlevan Duprat &lt;apahlevan@ieee.org&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'dt/name-hash-dir-entry-fix' into maint</title>
<updated>2015-11-03T23:32:40Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-11-03T23:32:40Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=3a27eec48ecfcc0764c90b3f478a124c01c082bc'/>
<id>urn:sha1:3a27eec48ecfcc0764c90b3f478a124c01c082bc</id>
<content type='text'>
The name-hash subsystem that is used to cope with case insensitive
filesystems keeps track of directories and their on-filesystem
cases for all the paths in the index by holding a pointer to a
randomly chosen cache entry that is inside the directory (for its
ce-&gt;ce_name component).  This pointer was not updated even when the
cache entry was removed from the index, leading to use after free.
This was fixed by recording the path for each directory instead of
borrowing cache entries and restructuring the API somewhat.

* dt/name-hash-dir-entry-fix:
  name-hash: don't reuse cache_entry in dir_entry
</content>
</entry>
<entry>
<title>Merge branch 'mk/submodule-gitdir-path' into maint</title>
<updated>2015-11-03T23:32:35Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-11-03T23:32:34Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=1bf986bc9c1e823da27465bfd9faf2b725bbcc09'/>
<id>urn:sha1:1bf986bc9c1e823da27465bfd9faf2b725bbcc09</id>
<content type='text'>
The submodule code has been taught to work better with separate
work trees created via "git worktree add".

* mk/submodule-gitdir-path:
  path: implement common_dir handling in git_pathdup_submodule()
  submodule refactor: use strbuf_git_path_submodule() in add_submodule_odb()
</content>
</entry>
<entry>
<title>Merge branch 'js/clone-dissociate' into maint</title>
<updated>2015-11-03T23:32:29Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-11-03T23:32:28Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=f836a32ba75beded3bca960f2918e08309642c62'/>
<id>urn:sha1:f836a32ba75beded3bca960f2918e08309642c62</id>
<content type='text'>
"git clone --dissociate" runs a big "git repack" process at the
end, and it helps to close file descriptors that are open on the
packs and their idx files before doing so on filesystems that
cannot remove a file that is still open.

* js/clone-dissociate:
  clone --dissociate: avoid locking pack files
  sha1_file.c: add a function to release all packs
  sha1_file: consolidate code to close a pack's file descriptor
  t5700: demonstrate a Windows file locking issue with `git clone --dissociate`
</content>
</entry>
<entry>
<title>Merge branch 'jk/repository-extension' into maint</title>
<updated>2015-11-03T23:32:25Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-11-03T23:32:25Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=f89baca1b99ff2882690d6b58dc2071195c6ae84'/>
<id>urn:sha1:f89baca1b99ff2882690d6b58dc2071195c6ae84</id>
<content type='text'>
Prepare for Git on-disk repository representation to undergo
backward incompatible changes by introducing a new repository
format version "1", with an extension mechanism.

* jk/repository-extension:
  introduce "preciousObjects" repository extension
  introduce "extensions" form of core.repositoryformatversion
</content>
</entry>
<entry>
<title>name-hash: don't reuse cache_entry in dir_entry</title>
<updated>2015-10-21T19:47:38Z</updated>
<author>
<name>David Turner</name>
<email>dturner@twopensource.com</email>
</author>
<published>2015-10-21T17:54:11Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=41284eb0f944fe2d73708bb4105a8e3ccd0297df'/>
<id>urn:sha1:41284eb0f944fe2d73708bb4105a8e3ccd0297df</id>
<content type='text'>
Stop reusing cache_entry in dir_entry; doing so causes a
use-after-free bug.

During merges, we free entries that we no longer need in the
destination index.  But those entries might have also been stored in
the dir_entry cache, and when a later call to add_to_index found them,
they would be used after being freed.

To prevent this, change dir_entry to store a copy of the name instead
of a pointer to a cache_entry.  This entails some refactoring of code
that expects the cache_entry.

Keith McGuigan &lt;kmcguigan@twitter.com&gt; diagnosed this bug and wrote
the initial patch, but this version does not use any of Keith's code.

Helped-by: Keith McGuigan &lt;kmcguigan@twitter.com&gt;
Helped-by: Junio C Hamano &lt;gitster@pobox.com&gt;
Signed-off-by: David Turner &lt;dturner@twopensource.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>sha1_file.c: add a function to release all packs</title>
<updated>2015-10-07T17:47:10Z</updated>
<author>
<name>Johannes Schindelin</name>
<email>johannes.schindelin@gmx.de</email>
</author>
<published>2015-10-06T13:18:34Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=38849a8116e690071c02eba0a8ef60a031a58080'/>
<id>urn:sha1:38849a8116e690071c02eba0a8ef60a031a58080</id>
<content type='text'>
On Windows, files that are in use cannot be removed or renamed. That
means that we have to release pack files when we are about to, say,
repack them. Let's introduce a convenient function to close all the
pack files and their idx files.

While at it, we consolidate the close windows/close fd/close index
stanza in `free_pack_by_name()` into the `close_pack()` function that
is used by the new `close_all_packs()` function to avoid repeated code.

Signed-off-by: Johannes Schindelin &lt;johannes.schindelin@gmx.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
