<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/object-file.c, branch v2.35.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.35.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.35.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2022-01-04T00:24:15Z</updated>
<entry>
<title>Merge branch 'ns/tmp-objdir'</title>
<updated>2022-01-04T00:24:15Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2022-01-04T00:24:14Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=0dc90d954db852c6604796b8d817365f94e92a16'/>
<id>urn:sha1:0dc90d954db852c6604796b8d817365f94e92a16</id>
<content type='text'>
New interface into the tmp-objdir API to help in-core use of the
quarantine feature.

* ns/tmp-objdir:
  tmp-objdir: disable ref updates when replacing the primary odb
  tmp-objdir: new API for creating temporary writable databases
</content>
</entry>
<entry>
<title>Merge branch 'ab/run-command'</title>
<updated>2021-12-15T17:39:47Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2021-12-15T17:39:47Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=832ec72c3e15820c3b728b3a56398655d7bb7cb3'/>
<id>urn:sha1:832ec72c3e15820c3b728b3a56398655d7bb7cb3</id>
<content type='text'>
API clean-up.

* ab/run-command:
  run-command API: remove "env" member, always use "env_array"
  difftool: use "env_array" to simplify memory management
  run-command API: remove "argv" member, always use "args"
  run-command API users: use strvec_push(), not argv construction
  run-command API users: use strvec_pushl(), not argv construction
  run-command tests: use strvec_pushv(), not argv assignment
  run-command API users: use strvec_pushv(), not argv assignment
  upload-archive: use regular "struct child_process" pattern
  worktree: stop being overly intimate with run_command() internals
</content>
</entry>
<entry>
<title>Merge branch 'hn/reftable'</title>
<updated>2021-12-15T17:39:45Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2021-12-15T17:39:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=a4bbd13be360d93f51a0cea6eef436db8622b592'/>
<id>urn:sha1:a4bbd13be360d93f51a0cea6eef436db8622b592</id>
<content type='text'>
The "reftable" backend for the refs API, without integrating into
the refs subsystem, has been added.

* hn/reftable:
  Add "test-tool dump-reftable" command.
  reftable: add dump utility
  reftable: implement stack, a mutable database of reftable files.
  reftable: implement refname validation
  reftable: add merged table view
  reftable: add a heap-based priority queue for reftable records
  reftable: reftable file level tests
  reftable: read reftable files
  reftable: generic interface to tables
  reftable: write reftable files
  reftable: a generic binary tree implementation
  reftable: reading/writing blocks
  Provide zlib's uncompress2 from compat/zlib-compat.c
  reftable: (de)serialization for the polymorphic record type.
  reftable: add blocksource, an abstraction for random access reads
  reftable: utility functions
  reftable: add error related functionality
  reftable: add LICENSE
  hash.h: provide constants for the hash IDs
</content>
</entry>
<entry>
<title>Merge branch 'po/size-t-for-vs'</title>
<updated>2021-12-10T22:35:10Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2021-12-10T22:35:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=cb136bd8521b6be057c08ab4cc92085030407d72'/>
<id>urn:sha1:cb136bd8521b6be057c08ab4cc92085030407d72</id>
<content type='text'>
On platforms where ulong is shorter than size_t, code paths that
shifted 1 or 1U to the left lacked the necessary cast to size_t,
which have been corrected.

* po/size-t-for-vs:
  object-file.c: LLP64 compatibility, upcast unity for left shift
  diffcore-delta.c: LLP64 compatibility, upcast unity for left shift
  repack.c: LLP64 compatibility, upcast unity for left shift
</content>
</entry>
<entry>
<title>tmp-objdir: disable ref updates when replacing the primary odb</title>
<updated>2021-12-08T22:06:46Z</updated>
<author>
<name>Neeraj Singh</name>
<email>neerajsi@microsoft.com</email>
</author>
<published>2021-12-06T22:05:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=ecd81dfc79cf12cc21fc0340da8ca8fcc5aa58a7'/>
<id>urn:sha1:ecd81dfc79cf12cc21fc0340da8ca8fcc5aa58a7</id>
<content type='text'>
When creating a subprocess with a temporary ODB, we set the
GIT_QUARANTINE_ENVIRONMENT env var to tell child Git processes not
to update refs, since the tmp-objdir may go away.

Introduce a similar mechanism for in-process temporary ODBs when
we call tmp_objdir_replace_primary_odb. Now both mechanisms set
the disable_ref_updates flag on the odb, which is queried by
the ref_transaction_prepare function.

Peff's test case [1] was invoking ref updates via the cachetextconv
setting. That particular code silently does nothing when a ref
update is forbidden. See the call to notes_cache_put in
fill_textconv where errors are ignored.

[1] https://lore.kernel.org/git/YVOn3hDsb5pnxR53@coredump.intra.peff.net/

Reported-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Neeraj Singh &lt;neerajsi@microsoft.com&gt;
Reviewed-by: Elijah Newren &lt;newren@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>tmp-objdir: new API for creating temporary writable databases</title>
<updated>2021-12-08T22:06:36Z</updated>
<author>
<name>Neeraj Singh</name>
<email>neerajsi@microsoft.com</email>
</author>
<published>2021-12-06T22:05:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=b3cecf49eac00d62e361bf6e6e81392f5a2fb571'/>
<id>urn:sha1:b3cecf49eac00d62e361bf6e6e81392f5a2fb571</id>
<content type='text'>
The tmp_objdir API provides the ability to create temporary object
directories, but was designed with the goal of having subprocesses
access these object stores, followed by the main process migrating
objects from it to the main object store or just deleting it.  The
subprocesses would view it as their primary datastore and write to it.

Here we add the tmp_objdir_replace_primary_odb function that replaces
the current process's writable "main" object directory with the
specified one. The previous main object directory is restored in either
tmp_objdir_migrate or tmp_objdir_destroy.

For the --remerge-diff usecase, add a new `will_destroy` flag in `struct
object_database` to mark ephemeral object databases that do not require
fsync durability.

Add 'git prune' support for removing temporary object databases, and
make sure that they have a name starting with tmp_ and containing an
operation-specific name.

Based-on-patch-by: Elijah Newren &lt;newren@gmail.com&gt;

Signed-off-by: Neeraj Singh &lt;neerajsi@microsoft.com&gt;
Reviewed-by: Elijah Newren &lt;newren@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>object-file.c: LLP64 compatibility, upcast unity for left shift</title>
<updated>2021-12-01T22:48:10Z</updated>
<author>
<name>Philip Oakley</name>
<email>philipoakley@iee.email</email>
</author>
<published>2021-12-01T00:29:02Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=26de1fc0c99026f341b8011957562991e4ea6c51'/>
<id>urn:sha1:26de1fc0c99026f341b8011957562991e4ea6c51</id>
<content type='text'>
Visual Studio reports C4334 "was 64-bit shift intended" warning because
of size miss-match.

Promote unity to the matching type to fit with the assignment.

Signed-off-by: Philip Oakley &lt;philipoakley@iee.email&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'mc/clean-smudge-with-llp64'</title>
<updated>2021-11-29T23:41:51Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2021-11-29T23:41:51Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=f9ba6acaa9348ea7b733bf78adc2f084247a912f'/>
<id>urn:sha1:f9ba6acaa9348ea7b733bf78adc2f084247a912f</id>
<content type='text'>
The clean/smudge conversion code path has been prepared to better
work on platforms where ulong is narrower than size_t.

* mc/clean-smudge-with-llp64:
  clean/smudge: allow clean filters to process extremely large files
  odb: guard against data loss checking out a huge file
  git-compat-util: introduce more size_t helpers
  odb: teach read_blob_entry to use size_t
  t1051: introduce a smudge filter test for extremely large files
  test-lib: add prerequisite for 64-bit platforms
  test-tool genzeros: generate large amounts of data more efficiently
  test-genzeros: allow more than 2G zeros in Windows
</content>
</entry>
<entry>
<title>run-command API: remove "env" member, always use "env_array"</title>
<updated>2021-11-26T06:15:08Z</updated>
<author>
<name>Ævar Arnfjörð Bjarmason</name>
<email>avarab@gmail.com</email>
</author>
<published>2021-11-25T22:52:24Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=c7c4bdeccf3e737e6e674cd9f0828922e629ab06'/>
<id>urn:sha1:c7c4bdeccf3e737e6e674cd9f0828922e629ab06</id>
<content type='text'>
Remove the "env" member from "struct child_process" in favor of always
using the "env_array". As with the preceding removal of "argv" in
favor of "args" this gets rid of current and future oddities around
memory management at the API boundary (see the amended API docs).

For some of the conversions we can replace patterns like:

    child.env = env-&gt;v;

With:

    strvec_pushv(&amp;child.env_array, env-&gt;v);

But for others we need to guard the strvec_pushv() with a NULL check,
since we're not passing in the "v" member of a "struct strvec",
e.g. in the case of tmp_objdir_env()'s return value.

Ideally we'd rename the "env_array" member to simply "env" as a
follow-up, since it and "args" are now inconsistent in not having an
"_array" suffix, and seemingly without any good reason, unless we look
at the history of how they came to be.

But as we've currently got 122 in-tree hits for a "git grep env_array"
let's leave that for now (and possibly forever). Doing that rename
would be too disruptive.

Signed-off-by: Ævar Arnfjörð Bjarmason &lt;avarab@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'ab/fsck-unexpected-type'</title>
<updated>2021-11-12T23:29:25Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2021-11-12T23:29:25Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=2c0fa66bc81a0725cd65fda69640552361536e50'/>
<id>urn:sha1:2c0fa66bc81a0725cd65fda69640552361536e50</id>
<content type='text'>
Regression fix.

* ab/fsck-unexpected-type:
  object-file: free(*contents) only in read_loose_object() caller
  object-file: fix SEGV on free() regression in v2.34.0-rc2
</content>
</entry>
</feed>
