Commit graph

65094 commits

Author SHA1 Message Date
Junio C Hamano 7b3fd03e6a Merge branch 'cm/drop-xunsetenv'
Drop a helper function that has never been used since its addition.

* cm/drop-xunsetenv:
  wrapper: remove xunsetenv()
2021-10-29 15:43:16 -07:00
Junio C Hamano a31efa77c6 Merge branch 'jk/log-warn-on-bogus-encoding'
Squelch over-eager warning message added during this cycle.

* jk/log-warn-on-bogus-encoding:
  log: document --encoding behavior on iconv() failure
  Revert "logmsg_reencode(): warn when iconv() fails"
2021-10-29 15:43:15 -07:00
Junio C Hamano 4d1ae1a605 Merge branch 'ab/unbundle-progress'
Doc clarification.

* ab/unbundle-progress:
  git-bundle.txt: add missing words and punctuation
2021-10-29 15:43:15 -07:00
Junio C Hamano 2343b75ca0 Merge branch 'jc/branch-copy-doc'
"git branch -c/-m new old" was not described to copy config, which
has been corrected.

* jc/branch-copy-doc:
  branch (doc): -m/-c copies config and reflog
2021-10-29 15:43:15 -07:00
Junio C Hamano fc0c491f65 Merge branch 'ma/doc-folder-to-directory'
Consistently use 'directory', not 'folder', to call the filesystem
entity that collects a group of files and, eh, directories.

* ma/doc-folder-to-directory:
  gitweb.txt: change "folder" to "directory"
  gitignore.txt: change "folder" to "directory"
  git-multi-pack-index.txt: change "folder" to "directory"
2021-10-29 15:43:15 -07:00
Junio C Hamano da007ba378 Merge branch 'sg/sparse-index-not-that-common-a-command'
Drop "git sparse-index" from the list of common commands.

* sg/sparse-index-not-that-common-a-command:
  command-list.txt: remove 'sparse-index' from main help
2021-10-29 15:43:15 -07:00
Junio C Hamano 8b3bef88f7 Merge branch 'ma/doc-git-version'
Typofix.

* ma/doc-git-version:
  git.txt: fix typo
2021-10-29 15:43:14 -07:00
Junio C Hamano cca0a9da05 Merge branch 'js/expand-runtime-prefix'
Typofix.

* js/expand-runtime-prefix:
  config.txt: fix typo
2021-10-29 15:43:14 -07:00
Junio C Hamano a0f604ee56 Merge branch 'bs/archive-doc-compression-level'
Update "git archive" documentation and give explicit mention on the
compression level for both zip and tar.gz format.

* bs/archive-doc-compression-level:
  archive: describe compression level option
2021-10-29 15:43:14 -07:00
Junio C Hamano f54c172bb3 Merge branch 'ks/submodule-add-message-fix'
Message regression fix.

* ks/submodule-add-message-fix:
  submodule: drop unused sm_name parameter from append_fetch_remotes()
  submodule--helper: fix incorrect newlines in an error message
2021-10-29 15:43:14 -07:00
Junio C Hamano dacf0acdf6 Merge branch 'ab/fix-make-lint-docs'
Hotfix for a topic recently merged to 'master'.

* ab/fix-make-lint-docs:
  Documentation/Makefile: fix lint-docs mkdir dependency
2021-10-29 15:43:13 -07:00
Junio C Hamano 942843e8dd Merge branch 'ab/sh-retire-rebase-preserve-merges'
Code clean-up to remove unused helpers.

* ab/sh-retire-rebase-preserve-merges:
  git-sh-setup: remove messaging supporting --preserve-merges
  git-sh-i18n: remove unused eval_ngettext()
2021-10-29 15:43:13 -07:00
Junio C Hamano 192a3fa31d Merge branch 'ab/plug-random-leaks'
Leakfix.

* ab/plug-random-leaks:
  reflog: free() ref given to us by dwim_log()
  submodule--helper: fix small memory leaks
  clone: fix a memory leak of the "git_dir" variable
  grep: fix a "path_list" memory leak
  grep: use object_array_clear() in cmd_grep()
  grep: prefer "struct grep_opt" over its "void *" equivalent
2021-10-29 15:43:13 -07:00
Junio C Hamano 55b99febc4 Merge branch 'ab/plug-handle-path-exclude-leak'
Leakfix.

* ab/plug-handle-path-exclude-leak:
  config.c: don't leak memory in handle_path_include()
2021-10-29 15:43:13 -07:00
Junio C Hamano c3673a8eb2 Merge branch 'ab/ref-filter-leakfix'
"git for-each-ref" family of commands were leaking the ref_sorting
instances that hold sorting keys specified by the user; this has
been corrected.

* ab/ref-filter-leakfix:
  branch: use ref_sorting_release()
  ref-filter API user: add and use a ref_sorting_release()
  tag: use a "goto cleanup" pattern, leak less memory
2021-10-29 15:43:12 -07:00
Junio C Hamano 735907bde1 Merge branch 'jk/http-push-status-fix'
"git push" client talking to an HTTP server did not diagnose the
lack of the final status report from the other side correctly,
which has been corrected.

* jk/http-push-status-fix:
  transport-helper: recognize "expecting report" error from send-pack
  send-pack: complain about "expecting report" with --helper-status
2021-10-29 15:43:12 -07:00
Junio C Hamano 8ba651b56e Merge branch 'ab/test-bail'
A new feature has been added to abort early in the test framework.

* ab/test-bail:
  test-lib.sh: use "Bail out!" syntax on bad SANITIZE=leak use
  test-lib.sh: de-duplicate error() teardown code
2021-10-29 15:43:12 -07:00
Junio C Hamano 23112fc28c Merge branch 'ab/make-sparse-for-real'
Fix-up for a recent topic.

* ab/make-sparse-for-real:
  Makefile: remove redundant GIT-CFLAGS dependency from "sparse"
2021-10-29 15:43:12 -07:00
Junio C Hamano 9ff67749fb Merge branch 'bs/doc-blame-color-lines'
Doc fix.

* bs/doc-blame-color-lines:
  git config doc: fix recent ASCIIDOC formatting regression
2021-10-29 15:43:12 -07:00
Junio C Hamano a38989bd5b unsetenv(3) returns int, not void
This compatilibity implementation has been returning a wrong type,
ever since 731043fd (Add compat/unsetenv.c ., 2006-01-25) added to
the system, yet nobody noticed it in the past 16 years, presumably
because no code checks failures in their unsetenv() calls.  Sigh.

For now, make it always succeed.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-29 15:00:58 -07:00
Carlo Marcelo Arenas Belón 6fc527a8d0 wrapper: remove xunsetenv()
Remove the unused wrapper function.

Reported-by: Randall S. Becker <rsbecker@nexbridge.com>
Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-29 14:59:29 -07:00
Jeff King 9e8fe7b1c7 log: document --encoding behavior on iconv() failure
We already note that we may produce invalid output when we skip calling
iconv() altogether. But we may also do so if iconv() fails, and we have
no good alternative. Let's document this to avoid surprising users.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-29 14:35:59 -07:00
Junio C Hamano 0988e665e9 Revert "logmsg_reencode(): warn when iconv() fails"
This reverts commit fd680bc5 (logmsg_reencode(): warn when iconv()
fails, 2021-08-27).  Throwing a warning for each and every commit
that gets reencoded, without allowing a way to squelch, would make
it unpleasant for folks who have to deal with an ancient part of the
history in an old project that used wrong encoding in the commits.
2021-10-29 13:48:58 -07:00
Alex Riesen fa21296b58 Document positive variant of commit and merge option "--no-verify"
This documents "--verify" option of the commands. It can be used to re-enable
the hooks disabled by an earlier "--no-verify" in command-line.

Signed-off-by: Alexander Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-29 11:22:56 -07:00
Junio C Hamano 361cb52383 pull: --ff-only should make it a noop when already-up-to-date
Earlier, we made sure that "git pull --ff-only" (and "git -c
pull.ff=only pull") errors out when our current HEAD is not an
ancestor of the tip of the history we are merging, but the condition
to trigger the error was implemented incorrectly.

Imagine you forked from a remote branch, built your history on top
of it, and then attempted to pull from them again.  If they have not
made any update in the meantime, our current HEAD is obviously not
their ancestor, and this new error triggers.

Without the --ff-only option, we just report that there is no need
to pull; we did the same historically with --ff-only, too.

Make sure we do not fail with the recently added check to restore
the historical behaviour.

Reported-by: Kenneth Arnold <ka37@calvin.edu>
Helped-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-29 00:15:39 -07:00
Jeff King 559664c792 t5310: drop lib-bundle.sh include
Commit ddfe900612 (test-lib-functions: move function to lib-bitmap.sh,
2021-02-09) meant to include lib-bitmap.sh in t5310, but also includes
lib-bundle.sh. Yet we don't use any of its functions, nor have anything
to do with bundles. This is probably just a typo/copy-paste error, as
lib-bundle.sh was added (correctly) to other scripts in the same series.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-29 00:06:12 -07:00
Taylor Blau 655b8561d6 pack-bitmap.c: more aggressively free in free_bitmap_index()
The function free_bitmap_index() is somewhat lax in what it frees. There
are two notable examples:

  - While it does call kh_destroy_oid_map on the "bitmaps" map, which
    maps commit OIDs to their corresponding bitmaps, the bitmaps
    themselves are not freed. Note here that we recycle already-freed
    ewah_bitmaps into a pool, but these are handled correctly by
    ewah_pool_free().

  - We never bother to free the extended index's "positions" map, which
    we always allocate in load_bitmap().

Fix both of these.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 15:32:14 -07:00
Taylor Blau 022815114a pack-bitmap.c: don't leak type-level bitmaps
test_bitmap_walk() is used to implement `git rev-list --test-bitmap`,
which compares the result of the on-disk bitmaps with ones generated
on-the-fly during a revision walk.

In fa95666a40 (pack-bitmap.c: harden 'test_bitmap_walk()' to check type
bitmaps, 2021-08-24), we hardened those tests to also check the four
special type-level bitmaps, but never freed those bitmaps. We should
have, since each required an allocation when we EWAH-decompressed them.

Free those, plugging that leak, and also free the base (the scratch-pad
bitmap), too.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 15:32:14 -07:00
Taylor Blau 60980aed78 midx.c: write MIDX filenames to strbuf
To ask for the name of a MIDX and its corresponding .rev file, callers
invoke get_midx_filename() and get_midx_rev_filename(), respectively.
These both invoke xstrfmt(), allocating a chunk of memory which must be
freed later on.

This makes callers in pack-bitmap.c somewhat awkward. Specifically,
midx_bitmap_filename(), which is implemented like:

    return xstrfmt("%s-%s.bitmap",
                   get_midx_filename(midx->object_dir),
                   hash_to_hex(get_midx_checksum(midx)));

this leaks the second argument to xstrfmt(), which itself was allocated
with xstrfmt(). This caller could assign both the result of
get_midx_filename() and the outer xstrfmt() to a temporary variable,
remembering to free() the former before returning. But that involves a
wasteful copy.

Instead, get_midx_filename() and get_midx_rev_filename() take a strbuf
as an output parameter. This way midx_bitmap_filename() can manipulate
and pass around a temporary buffer which it detaches back to its caller.

That allows us to implement the function without copying or open-coding
get_midx_filename() in a way that doesn't leak.

Update the other callers of get_midx_filename() and
get_midx_rev_filename() accordingly.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 15:32:14 -07:00
Taylor Blau ee4a1d63d7 builtin/multi-pack-index.c: don't leak concatenated options
The `multi-pack-index` builtin dynamically allocates an array of
command-line option for each of its separate modes by calling
add_common_options() to concatante the common options with sub-command
specific ones.

Because this operation allocates a new array, we have to be careful to
remember to free it. We already do this in the repack and write
sub-commands, but verify and expire don't. Rectify this by calling
FREE_AND_NULL as the other modes do.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 15:32:14 -07:00
Taylor Blau e6432e0f1f builtin/repack.c: avoid leaking child arguments
`git repack` invokes a handful of child processes: one to write the
actual pack, and optionally ones to repack promisor objects and update
the MIDX.

Most of these are freed automatically by calling `start_command()` (which
invokes it on error) and `finish_command()` which calls it
automatically.

But repack_promisor_objects() can initialize a child_process, populate
its array of arguments, and then return from the function before even
calling start_command().

Make sure that the prepared list of arguments is freed by calling
child_process_clear() ourselves to avoid leaking memory along this path.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 15:31:51 -07:00
Sergey Organov a8a6e0682d stash: get rid of unused argument in stash_staged()
Unused 'ps' argument was a left-over from original copy-paste of
stash_patch(). Removed.

Signed-off-by: Sergey Organov <sorganov@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 14:17:14 -07:00
Alex Riesen 47bfdfb3fd pull: honor --no-verify and do not call the commit-msg hook
The option was incorrectly auto-translated to "--no-verify-signatures",
which causes the unexpected effect of the hook being called.
And an even more unexpected effect of disabling verification of signatures.

The manual page describes the option to behave same as the similarly
named option of "git merge", which seems to be the original intention
of this option in the "pull" command.

Signed-off-by: Alexander Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 09:52:09 -07:00
Robert Estelle 46b0585286 completion: fix incorrect bash/zsh string equality check
In the basic `[`/`test` command, the string equality operator is a
single `=`. The `==` operator is only available in `[[`, which is a
bash-ism also supported by zsh.

This mix-up was causing the following completion error in zsh:
> __git_ls_files_helper:7: = not found

(That message refers to the extraneous symbol in `==` ← `=`).

This updates that comparison to use a single `=` inside the
basic `[ … ]` test conditional.

Although this fix is inconsistent with the other comparisons in this
file, which use `[[ … == … ]]`, and the two expressions are functionally
identical in this context, that approach was rejected due to a
preference for `[`.

Signed-off-by: Robert Estelle <robertestelle@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 09:33:19 -07:00
Thiago Perrotta a2ce608244 send-email docs: add format-patch options
git-send-email(1) does not mention that "git format-patch" options are
accepted. Augment SYNOPSIS and DESCRIPTION to mention it.

Update git-send-email.perl USAGE to be consistent with
git-send-email(1).

Signed-off-by: Thiago Perrotta <tbperrotta@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 09:06:15 -07:00
Thiago Perrotta 2b7b75850c send-email: programmatically generate bash completions
"git send-email --git-completion-helper" only prints "format-patch"
flags. Make it print "send-email" flags as well, extracting them
programmatically from its three existing "GetOptions".

Introduce a "uniq" subroutine, otherwise --cc-cover, --to-cover and
other flags would show up twice. In addition, deduplicate flags common
to both "send-email" and "format-patch", like --from.

Remove extraneous flags: --h and --git-completion-helper.

Add trailing "=" to options that expect an argument, inline with
the format-patch implementation.

Add a completion test for "send-email --validate", a send-email flag.

Signed-off-by: Thiago Perrotta <tbperrotta@gmail.com>
Based-on-patch-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 09:04:24 -07:00
Matheus Tavares 20141e322c add, rm, mv: fix bug that prevents the update of non-sparse dirs
These three commands recently learned to avoid updating paths outside
the sparse checkout even if they are missing the SKIP_WORKTREE bit. This
is done using path_in_sparse_checkout(), which checks whether a given
path matches the current list of sparsity rules, similar to what
clear_ce_flags() does when we run "git sparse checkout init" or "git
sparse-checkout reapply". However, clear_ce_flags() uses a recursive
approach, applying the match results from parent directories on paths
that get the UNDECIDED result, whereas path_in_sparse_checkout() only
attempts to match the full path and immediately considers UNDECIDED as
NOT_MATCHED. This makes the function miss matches with leading
directories. For example, if the user has the sparsity patterns "!/a"
and "b/", add, rm, and mv will fail to update the path "a/b/c" and end
up displaying a warning about it being outside the sparse checkout even
though it isn't. This problem only occurs in full pattern mode as the
pattern matching functions never return UNDECIDED for cone mode.

To fix this, replicate the recursive behavior of clear_ce_flags() in
path_in_sparse_checkout(), falling back to the parent directory match
when a path gets the UNDECIDED result. (If this turns out to be too
expensive in some cases, we may want to later add some form of caching
to accelerate multiple queries within the same directory. This is not
implemented in this patch, though.) Also add two tests for each affected
command (add, rm, and mv) to check that they behave correctly with the
recursive pattern matching. The first test would previously fail without
this patch while the second already succeeded. It is added mostly to
make sure that we are not breaking the existing pattern matching for
directories that are really sparse, and also as a protection against any
future regressions.

Two other existing tests had to be changed as well: one test in t3602
checks that "git rm -r <dir>" won't remove sparse entries, but it didn't
allow the non-sparse entries inside <dir> to be removed. The other one,
in t7002, tested that "git mv" would correctly display a warning message
for sparse paths, but it accidentally expected the message to include
two non-sparse paths as well.

Signed-off-by: Matheus Tavares <matheus.bernardino@usp.br>
Acked-by: Derrick Stolee <dstolee@microsoft.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-28 08:46:07 -07:00
Martin Ågren a4dfb4491e git-bundle.txt: add missing words and punctuation
Add an "and" to separate the two halves of the first sentence of the
paragraph more. Add a comma to similarly separate the two halves of the
second sentence a bit better. Add a period at the end of the paragraph.

Further down in the file, add the missing "be" in "must be accompanied".

Signed-off-by: Martin Ågren <martin.agren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-27 17:06:12 -07:00
Jeff King 4c64fb5aad Documentation/Makefile: fix lint-docs mkdir dependency
Since 8650c6298c (doc lint: make "lint-docs" non-.PHONY, 2021-10-15), we
put the output for gitlink linter into .build/lint-docs/gitlink. There
are order-only dependencies to create the sequence of subdirs like:

  .build/lint-docs: | .build
          $(QUIET)mkdir $@
  .build/lint-docs/gitlink: | .build/lint-docs
          $(QUIET)mkdir $@

where each level has to depend on the prior one (since the parent
directory must exist for us to create something inside it). But the
"howto" and "config" subdirectories of gitlink have the wrong
dependency; they depend on "lint-docs", not "lint-docs/gitlink".

This usually works out, because the LINT_DOCS_GITLINK targets which
depend on "gitlink/howto" also depend on just "gitlink", so the
directory gets created anyway. But since we haven't given make an
explicit ordering, things can racily happen out of order.

If you stick a "sleep 1" in the rule to build "gitlink" like this:

   ## Lint: gitlink
   .build/lint-docs/gitlink: | .build/lint-docs
  -	$(QUIET)mkdir $@
  +	$(QUIET)sleep 1 && mkdir $@

then "make clean; make lint-docs" will fail reliably. Or you can see it
as-is just by building the directory in isolation:

  $ make clean
  [...]
  $ make .build/lint-docs/gitlink/howto
      GEN mergetools-list.made
      GEN cmd-list.made
      GEN doc.dep
      SUBDIR ../
  make[1]: 'GIT-VERSION-FILE' is up to date.
      SUBDIR ../
  make[1]: 'GIT-VERSION-FILE' is up to date.
  mkdir: cannot create directory ‘.build/lint-docs/gitlink/howto’: No such file or directory
  make: *** [Makefile:476: .build/lint-docs/gitlink/howto] Error 1

The fix is easy: we just need to depend on the correct parent directory.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-27 16:57:14 -07:00
Taylor Blau 9e39acc94a builtin/pack-objects.c: don't leak memory via arguments
When constructing arguments to pass to setup_revision(), pack-objects
only frees the memory used by that array after calling
get_object_list().

Ensure that we call strvec_clear() whether or not we use the arguments
array by cleaning up whenever we exit the function (and rewriting one
early return to jump to a label which frees the memory and then
returns).

We could avoid setting this array up altogether unless we are in the
if-else block that calls get_object_list(), but setting up the argument
array is intermingled with lots of other side-effects, e.g.:

    if (exclude_promisor_objects) {
      use_internal_rev_list = 1;
      fetch_if_missing = 0;
      strvec_push(&rp, "--exclude-promisor-objects");
    }

So it would be awkward to check exclude_promisor_objects twice: first to
set use_internal_rev_list and fetch_if_missing, and then again above
get_object_list() to push the relevant argument onto the array.

Instead, leave the array's construction alone and make sure to free it
unconditionally.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-27 16:26:37 -07:00
Taylor Blau 7f4c3508c0 t/helper/test-read-midx.c: free MIDX within read_midx_file()
When calling `read_midx_file()` to show information about a MIDX or list
the objects contained within it we fail to call `close_midx()`, leaking
the memory allocated to store that MIDX.

Fix this by calling `close_midx()` before exiting the function. We can
drop the "early" return when `show_objects` is non-zero, since the next
instruction is also a return.

(We could just as easily put a `cleanup` label here as with previous
patches. But the only other time we terminate the function early is
when we fail to load a MIDX in the first place. `close_midx()` does
handle a NULL argument, but the extra complexity is likely not
warranted).

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-27 16:26:37 -07:00
Taylor Blau 492cb394fb midx.c: don't leak MIDX from verify_midx_file
The function midx.c:verify_midx_file() allocates a MIDX struct by
calling load_multi_pack_index(). But when cleaning up, it calls free()
without freeing any resources associated with the MIDX.

Call the more appropriate close_midx() which does free those resources,
which causes t5319.3 to pass when Git is compiled with SANITIZE=leak.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-27 16:26:37 -07:00
Jeff King 6b615dbece submodule: drop unused sm_name parameter from append_fetch_remotes()
Commit c21fb4676f (submodule--helper: fix incorrect newlines in an error
message, 2021-10-23) accidentally added a new, unused parameter while
changing the name and signature of show_fetch_remotes() to
append_fetch_remotes(). We can drop this to keep things simpler (and
satisfy -Wunused-parameter).

The error is likely because c21fb4676f is fixing a problem from
8c8195e9c3 (submodule--helper: introduce add-clone subcommand,
2021-07-10). An earlier iteration of that second commit introduced the
same unused parameter (though it was dropped before it finally made it
to 'next'), and the fix on top accidentally carried forward the extra
parameter.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-27 10:42:11 -07:00
Junio C Hamano e9e5ba39a7 The fifteenth batch
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-25 16:07:12 -07:00
Junio C Hamano c6fc44e9bf Merge branch 'ab/test-lib-diff-cleanup'
Test clean-up.

* ab/test-lib-diff-cleanup:
  tests: stop using top-level "README" and "COPYING" files
  "lib-diff" tests: make "README" and "COPYING" test data smaller
2021-10-25 16:07:01 -07:00
Junio C Hamano 63ec2297d2 Merge branch 'ab/fix-make-lint-docs'
Build fix.

* ab/fix-make-lint-docs:
  doc lint: make "lint-docs" non-.PHONY
  doc build: speed up "make lint-docs"
  doc lint: emit errors on STDERR
  doc lint: fix error-hiding regression
2021-10-25 16:07:01 -07:00
Junio C Hamano 06355d72dc Merge branch 'ab/pkt-line-cleanup'
Code clean-up.

* ab/pkt-line-cleanup:
  pkt-line.[ch]: remove unused packet_read_line_buf()
  pkt-line.[ch]: remove unused packet_buf_write_len()
2021-10-25 16:07:00 -07:00
Junio C Hamano d54fd59d84 Merge branch 'tb/fix-midx-rename-while-mapped'
The codepath to write a new version of .midx multi-pack index files
has learned to release the mmaped memory holding the current
version of .midx before removing them from the disk, as some
platforms do not allow removal of a file that still has mapping.

* tb/fix-midx-rename-while-mapped:
  midx.c: guard against commit_lock_file() failures
  midx.c: lookup MIDX by object directory during repack
  midx.c: lookup MIDX by object directory during expire
  midx.c: extract MIDX lookup by object_dir
2021-10-25 16:07:00 -07:00
Junio C Hamano 67f310e1ad Merge branch 'ab/test-cleanly-recreate-trash-directory'
Improve test framework around unwritable directories.

* ab/test-cleanly-recreate-trash-directory:
  test-lib.sh: try to re-chmod & retry on failed trash removal
2021-10-25 16:07:00 -07:00
Junio C Hamano 97ab03b12a Merge branch 'jc/doc-commit-header-continuation-line'
Doc update.

* jc/doc-commit-header-continuation-line:
  signature-format.txt: explain and illustrate multi-line headers
2021-10-25 16:07:00 -07:00