aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Documentation/BreakingChanges.txt2
-rw-r--r--Documentation/DecisionMaking.txt2
-rw-r--r--Documentation/RelNotes/2.47.0.txt5
-rw-r--r--Documentation/config/extensions.txt2
-rw-r--r--Documentation/config/gc.txt2
-rw-r--r--Documentation/config/remote.txt2
-rw-r--r--Documentation/gitformat-commit-graph.txt2
-rw-r--r--Documentation/gitweb.txt2
-rw-r--r--Documentation/howto/maintain-git.txt17
-rw-r--r--archive.c3
-rw-r--r--builtin/fsmonitor--daemon.c1
-rw-r--r--hash.h3
-rw-r--r--mergetools/vimdiff2
-rw-r--r--perl/Git/I18N.pm2
-rw-r--r--read-cache.c1
-rw-r--r--reftable/reader.h2
-rwxr-xr-xt/t0610-reftable-basics.sh17
-rwxr-xr-xt/t7527-builtin-fsmonitor.sh51
-rw-r--r--t/test-lib-functions.sh3
-rw-r--r--t/test-lib.sh41
-rw-r--r--trace2/tr2_ctr.c2
-rw-r--r--trace2/tr2_tls.h2
-rw-r--r--utf8.h5
23 files changed, 114 insertions, 57 deletions
diff --git a/Documentation/BreakingChanges.txt b/Documentation/BreakingChanges.txt
index 2b64665694..112770a9da 100644
--- a/Documentation/BreakingChanges.txt
+++ b/Documentation/BreakingChanges.txt
@@ -117,7 +117,7 @@ Cf. <20140304174806.GA11561@sigill.intra.peff.net>.
* The git-pack-redundant(1) command can be used to remove redundant pack files.
The subcommand is unusably slow and the reason why nobody reports it as a
- performance bug is suspected to be the absense of users. We have nominated
+ performance bug is suspected to be the absence of users. We have nominated
the command for removal and have started to emit a user-visible warning in
c3b58472be (pack-redundant: gauge the usage before proposing its removal,
2020-08-25) whenever the command is executed.
diff --git a/Documentation/DecisionMaking.txt b/Documentation/DecisionMaking.txt
index dbb4c1f569..b43c472ae5 100644
--- a/Documentation/DecisionMaking.txt
+++ b/Documentation/DecisionMaking.txt
@@ -54,7 +54,7 @@ implementation, for very large changes).
For non-technical decisions such as community norms or processes, it is up to
the community as a whole to implement and sustain agreed-upon changes.
-The project leadership committe (PLC) may help the implementation of
+The project leadership committee (PLC) may help the implementation of
policy decisions.
diff --git a/Documentation/RelNotes/2.47.0.txt b/Documentation/RelNotes/2.47.0.txt
index e13c37f5dd..b63c3364af 100644
--- a/Documentation/RelNotes/2.47.0.txt
+++ b/Documentation/RelNotes/2.47.0.txt
@@ -328,6 +328,9 @@ Fixes since v2.46
index" advice message, which has been corrected.
(merge 537e516a39 ds/sparse-checkout-expansion-advice later to maint).
+ * macOS with fsmonitor daemon can hang forever when a submodule is
+ involved, which has been corrected.
+
* Other code cleanup, docfix, build fix, etc.
(merge be10ac7037 jc/mailinfo-header-cleanup later to maint).
(merge 4460e052e0 jc/range-diff-lazy-setup later to maint).
@@ -335,3 +338,5 @@ Fixes since v2.46
(merge 83799f1500 jk/t9001-deflake later to maint).
(merge e02cc08a88 ak/typofix-2.46-maint later to maint).
(merge 5c5d29e1c4 ps/ci-gitlab-upgrade later to maint).
+ (merge 9c4c840901 jc/doc-discarding-stalled-topics later to maint).
+ (merge 5e6f359f6b ds/read-cache-mempool-leakfix later to maint).
diff --git a/Documentation/config/extensions.txt b/Documentation/config/extensions.txt
index 38dce3df35..f0a784447d 100644
--- a/Documentation/config/extensions.txt
+++ b/Documentation/config/extensions.txt
@@ -9,7 +9,7 @@ work and will produce hard-to-diagnose issues.
extensions.compatObjectFormat::
- Specify a compatitbility hash algorithm to use. The acceptable values
+ Specify a compatibility hash algorithm to use. The acceptable values
are `sha1` and `sha256`. The value specified must be different from the
value of extensions.objectFormat. This allows client level
interoperability between git repositories whose objectFormat matches
diff --git a/Documentation/config/gc.txt b/Documentation/config/gc.txt
index 1d4f9470ea..21d56db279 100644
--- a/Documentation/config/gc.txt
+++ b/Documentation/config/gc.txt
@@ -163,7 +163,7 @@ gc.repackFilterTo::
containing the filtered out objects. **WARNING:** The
specified location should be accessible, using for example the
Git alternates mechanism, otherwise the repo could be
- considered corrupt by Git as it migh not be able to access the
+ considered corrupt by Git as it might not be able to access the
objects in that packfile. See the `--filter-to=<dir>` option
of linkgit:git-repack[1] and the `objects/info/alternates`
section of linkgit:gitrepository-layout[5].
diff --git a/Documentation/config/remote.txt b/Documentation/config/remote.txt
index 36e771556c..71d1fee835 100644
--- a/Documentation/config/remote.txt
+++ b/Documentation/config/remote.txt
@@ -50,7 +50,7 @@ remote.<name>.skipFetchAll::
If true, this remote will be skipped when updating
using linkgit:git-fetch[1], the `update` subcommand of
linkgit:git-remote[1], and ignored by the prefetch task
- of `git maitenance`.
+ of `git maintenance`.
remote.<name>.receivepack::
The default program to execute on the remote side when pushing. See
diff --git a/Documentation/gitformat-commit-graph.txt b/Documentation/gitformat-commit-graph.txt
index 3e906e8030..14d1631234 100644
--- a/Documentation/gitformat-commit-graph.txt
+++ b/Documentation/gitformat-commit-graph.txt
@@ -122,7 +122,7 @@ All multi-byte numbers are in network byte order.
for commits with corrected commit date offsets that cannot be
stored within 31 bits.
* Generation Data Overflow chunk is present only when Generation Data
- chunk is present and atleast one corrected commit date offset cannot
+ chunk is present and at least one corrected commit date offset cannot
be stored within 31 bits.
==== Extra Edge List (ID: {'E', 'D', 'G', 'E'}) [Optional]
diff --git a/Documentation/gitweb.txt b/Documentation/gitweb.txt
index 56d24a30a3..5e2b491ec2 100644
--- a/Documentation/gitweb.txt
+++ b/Documentation/gitweb.txt
@@ -234,7 +234,7 @@ from the template during repository creation, usually installed in
configuration variable, but the file takes precedence.
category (or `gitweb.category`)::
- Singe line category of a project, used to group projects if
+ Single line category of a project, used to group projects if
`$projects_list_group_categories` is enabled. By default (file and
configuration variable absent), uncategorized projects are put in the
`$project_list_default_category` category. You can use the
diff --git a/Documentation/howto/maintain-git.txt b/Documentation/howto/maintain-git.txt
index da31332f11..e797b32522 100644
--- a/Documentation/howto/maintain-git.txt
+++ b/Documentation/howto/maintain-git.txt
@@ -67,7 +67,22 @@ the mailing list after each feature release is made:
before getting merged to 'master'.
- 'seen' branch is used to publish other proposed changes that do
- not yet pass the criteria set for 'next' (see above).
+ not yet pass the criteria set for 'next' (see above), but there
+ is no promise that 'seen' will contain everything. A topic that
+ had no reviewer reaction may not be picked up.
+
+ - A new topic will first get merged to 'seen', unless it is
+ trivially correct and clearly urgent, in which case it may be
+ directly merged to 'next' or even to 'master'.
+
+ - If a topic that was picked up to 'seen' becomes and stays
+ inactive for 3 calendar weeks without having seen a clear
+ consensus that it is good enough to be moved to 'next', the
+ topic may be discarded from 'seen'. Interested parties are
+ still free to revive the topic. For the purpose of this
+ guideline, the definition of being "inactive" is that nobody
+ has discussed the topic, no new iteration of the topic was
+ posted, and no responses to the review comments were given.
- The tips of 'master' and 'maint' branches will not be rewound to
allow people to build their own customization on top of them.
diff --git a/archive.c b/archive.c
index 58f86bf75c..a7a92ff839 100644
--- a/archive.c
+++ b/archive.c
@@ -536,7 +536,8 @@ static void parse_treeish_arg(const char **argv,
opts.fn = oneway_merge;
init_tree_desc(&t, &tree->object.oid, tree->buffer, tree->size);
if (unpack_trees(1, &t, &opts))
- die(_("unable to checkout working tree"));
+ die(_("failed to unpack tree object %s"),
+ oid_to_hex(&tree->object.oid));
git_attr_set_direction(GIT_ATTR_INDEX);
}
diff --git a/builtin/fsmonitor--daemon.c b/builtin/fsmonitor--daemon.c
index dce8a3b248..e1e6b96d09 100644
--- a/builtin/fsmonitor--daemon.c
+++ b/builtin/fsmonitor--daemon.c
@@ -1314,6 +1314,7 @@ static int fsmonitor_run_daemon(void)
strbuf_reset(&state.path_gitdir_watch);
strbuf_addstr(&state.path_gitdir_watch,
absolute_path(repo_get_git_dir(the_repository)));
+ strbuf_strip_suffix(&state.path_gitdir_watch, "/.");
state.nr_paths_watching = 2;
}
diff --git a/hash.h b/hash.h
index f97f858307..756166ce5e 100644
--- a/hash.h
+++ b/hash.h
@@ -82,6 +82,9 @@
# ifdef platform_SHA1_Clone
# define platform_SHA1_Clone_unsafe platform_SHA1_Clone
# endif
+# ifdef SHA1_NEEDS_CLONE_HELPER
+# define SHA1_NEEDS_CLONE_HELPER_UNSAFE
+# endif
#endif
#define git_SHA_CTX platform_SHA_CTX
diff --git a/mergetools/vimdiff b/mergetools/vimdiff
index f8ad6b35d4..ffc9be86c8 100644
--- a/mergetools/vimdiff
+++ b/mergetools/vimdiff
@@ -411,7 +411,7 @@ merge_cmd () {
-f "$FINAL_CMD" '"$LOCAL"' '"$BASE"' '"$REMOTE"' '"$MERGED"'
else
# If there is no BASE (example: a merge conflict in a new file
- # with the same name created in both braches which didn't exist
+ # with the same name created in both branches which didn't exist
# before), close all BASE windows using vim's "quit" command
FINAL_CMD=$(echo "$FINAL_CMD" | \
diff --git a/perl/Git/I18N.pm b/perl/Git/I18N.pm
index 5454c3a6d2..475e90a6df 100644
--- a/perl/Git/I18N.pm
+++ b/perl/Git/I18N.pm
@@ -111,7 +111,7 @@ L<Locale::Messages>'s ngettext function or passthrough fallback function.
=head2 N__($)
No-operation that only returns its argument. Use this if you want xgettext to
-extract the text to the pot template but do not want to trigger retrival of the
+extract the text to the pot template but do not want to trigger retrieval of the
translation at run time.
=head1 AUTHOR
diff --git a/read-cache.c b/read-cache.c
index 764fdfec46..3c078afadb 100644
--- a/read-cache.c
+++ b/read-cache.c
@@ -2188,6 +2188,7 @@ static unsigned long load_cache_entries_threaded(struct index_state *istate, con
if (err)
die(_("unable to join load_cache_entries thread: %s"), strerror(err));
mem_pool_combine(istate->ce_mem_pool, p->ce_mem_pool);
+ free(p->ce_mem_pool);
consumed += p->consumed;
}
diff --git a/reftable/reader.h b/reftable/reader.h
index 3710ee09b4..91377b9ce5 100644
--- a/reftable/reader.h
+++ b/reftable/reader.h
@@ -30,7 +30,7 @@ struct reftable_reader_offsets {
/* The state for reading a reftable file. */
struct reftable_reader {
- /* for convience, associate a name with the instance. */
+ /* for convenience, associate a name with the instance. */
char *name;
struct reftable_block_source source;
diff --git a/t/t0610-reftable-basics.sh b/t/t0610-reftable-basics.sh
index 2d951c8ceb..babec7993e 100755
--- a/t/t0610-reftable-basics.sh
+++ b/t/t0610-reftable-basics.sh
@@ -450,15 +450,22 @@ test_expect_success 'ref transaction: retry acquiring tables.list lock' '
)
'
-test_expect_success 'ref transaction: many concurrent writers' '
+# This test fails most of the time on Windows systems. The root cause is
+# that Windows does not allow us to rename the "tables.list.lock" file into
+# place when "tables.list" is open for reading by a concurrent process.
+test_expect_success !WINDOWS 'ref transaction: many concurrent writers' '
test_when_finished "rm -rf repo" &&
git init repo &&
(
cd repo &&
- # Set a high timeout such that a busy CI machine will not abort
- # early. 10 seconds should hopefully be ample of time to make
- # this non-flaky.
- git config set reftable.lockTimeout 10000 &&
+ # Set a high timeout. While a couple of seconds should be
+ # plenty, using the address sanitizer will significantly slow
+ # us down here. So we are aiming way higher than you would ever
+ # think is necessary just to keep us from flaking. We could
+ # also lock indefinitely by passing -1, but that could
+ # potentially block CI jobs indefinitely if there was a bug
+ # here.
+ git config set reftable.lockTimeout 300000 &&
test_commit --no-tag initial &&
head=$(git rev-parse HEAD) &&
diff --git a/t/t7527-builtin-fsmonitor.sh b/t/t7527-builtin-fsmonitor.sh
index 730f3c7f81..9b15baa02d 100755
--- a/t/t7527-builtin-fsmonitor.sh
+++ b/t/t7527-builtin-fsmonitor.sh
@@ -907,6 +907,57 @@ test_expect_success "submodule absorbgitdirs implicitly starts daemon" '
test_subcommand git fsmonitor--daemon start <super-sub.trace
'
+start_git_in_background () {
+ git "$@" &
+ git_pid=$!
+ git_pgid=$(ps -o pgid= -p $git_pid)
+ nr_tries_left=10
+ while true
+ do
+ if test $nr_tries_left -eq 0
+ then
+ kill -- -$git_pgid
+ exit 1
+ fi
+ sleep 1
+ nr_tries_left=$(($nr_tries_left - 1))
+ done >/dev/null 2>&1 &
+ watchdog_pid=$!
+ wait $git_pid
+}
+
+stop_git () {
+ while kill -0 -- -$git_pgid
+ do
+ kill -- -$git_pgid
+ sleep 1
+ done
+}
+
+stop_watchdog () {
+ while kill -0 $watchdog_pid
+ do
+ kill $watchdog_pid
+ sleep 1
+ done
+}
+
+test_expect_success !MINGW "submodule implicitly starts daemon by pull" '
+ test_atexit "stop_watchdog" &&
+ test_when_finished "stop_git; rm -rf cloned super sub" &&
+
+ create_super super &&
+ create_sub sub &&
+
+ git -C super submodule add ../sub ./dir_1/dir_2/sub &&
+ git -C super commit -m "add sub" &&
+ git clone --recurse-submodules super cloned &&
+
+ git -C cloned/dir_1/dir_2/sub config core.fsmonitor true &&
+ set -m &&
+ start_git_in_background -C cloned pull --recurse-submodules
+'
+
# On a case-insensitive file system, confirm that the daemon
# notices when the .git directory is moved/renamed/deleted
# regardless of how it is spelled in the FS event.
diff --git a/t/test-lib-functions.sh b/t/test-lib-functions.sh
index fde9bf54fc..78e054ab50 100644
--- a/t/test-lib-functions.sh
+++ b/t/test-lib-functions.sh
@@ -926,7 +926,8 @@ test_expect_success () {
test_body_or_stdin test_body "$2"
test -n "$test_skip_test_preamble" ||
say >&3 "expecting success of $TEST_NUMBER.$test_count '$1': $test_body"
- if test_run_ "$test_body"
+ if test_run_ "$test_body" &&
+ check_test_results_san_file_empty_
then
test_ok_ "$1"
else
diff --git a/t/test-lib.sh b/t/test-lib.sh
index e718efe4c6..b1a8ee5c00 100644
--- a/t/test-lib.sh
+++ b/t/test-lib.sh
@@ -322,7 +322,6 @@ TEST_RESULTS_SAN_FILE_PFX=trace
TEST_RESULTS_SAN_DIR_SFX=leak
TEST_RESULTS_SAN_FILE=
TEST_RESULTS_SAN_DIR="$TEST_RESULTS_DIR/$TEST_NAME.$TEST_RESULTS_SAN_DIR_SFX"
-TEST_RESULTS_SAN_DIR_NR_LEAKS_STARTUP=
TRASH_DIRECTORY="trash directory.$TEST_NAME$TEST_STRESS_JOB_SFX"
test -n "$root" && TRASH_DIRECTORY="$root/$TRASH_DIRECTORY"
case "$TRASH_DIRECTORY" in
@@ -848,6 +847,7 @@ test_failure_ () {
GIT_EXIT_OK=t
exit 0
fi
+ check_test_results_san_file_ "$test_failure"
_error_exit
fi
finalize_test_case_output failure "$failure_label" "$@"
@@ -1215,42 +1215,16 @@ test_atexit_handler () {
teardown_malloc_check
}
-sanitize_leak_log_message_ () {
- local new="$1" &&
- local old="$2" &&
- local file="$3" &&
-
- printf "With SANITIZE=leak at exit we have %d leak logs, but started with %d
-
-This means that we have a blindspot where git is leaking but we're
-losing the exit code somewhere, or not propagating it appropriately
-upwards!
-
-See the logs at \"%s.*\";
-those logs are reproduced below." \
- "$new" "$old" "$file"
+check_test_results_san_file_empty_ () {
+ test -z "$TEST_RESULTS_SAN_FILE" ||
+ test "$(nr_san_dir_leaks_)" = 0
}
check_test_results_san_file_ () {
- if test -z "$TEST_RESULTS_SAN_FILE"
+ if check_test_results_san_file_empty_
then
return
fi &&
- local old="$TEST_RESULTS_SAN_DIR_NR_LEAKS_STARTUP" &&
- local new="$(nr_san_dir_leaks_)" &&
-
- if test $new -le $old
- then
- return
- fi &&
- local out="$(sanitize_leak_log_message_ "$new" "$old" "$TEST_RESULTS_SAN_FILE")" &&
- say_color error "$out" &&
- if test "$old" != 0
- then
- echo &&
- say_color error "The logs include output from past runs to avoid" &&
- say_color error "that remove 'test-results' between runs."
- fi &&
say_color error "$(cat "$TEST_RESULTS_SAN_FILE".*)" &&
if test -n "$passes_sanitize_leak" && test "$test_failure" = 0
@@ -1586,16 +1560,13 @@ then
test_done
fi
+ rm -rf "$TEST_RESULTS_SAN_DIR"
if ! mkdir -p "$TEST_RESULTS_SAN_DIR"
then
BAIL_OUT "cannot create $TEST_RESULTS_SAN_DIR"
fi &&
TEST_RESULTS_SAN_FILE="$TEST_RESULTS_SAN_DIR/$TEST_RESULTS_SAN_FILE_PFX"
- # In case "test-results" is left over from a previous
- # run: Only report if new leaks show up.
- TEST_RESULTS_SAN_DIR_NR_LEAKS_STARTUP=$(nr_san_dir_leaks_)
-
# Don't litter *.leak dirs if there was nothing to report
test_atexit "rmdir \"$TEST_RESULTS_SAN_DIR\" 2>/dev/null || :"
diff --git a/trace2/tr2_ctr.c b/trace2/tr2_ctr.c
index 036b643578..ee17bfa86b 100644
--- a/trace2/tr2_ctr.c
+++ b/trace2/tr2_ctr.c
@@ -4,7 +4,7 @@
#include "trace2/tr2_ctr.h"
/*
- * A global counter block to aggregrate values from the partial sums
+ * A global counter block to aggregate values from the partial sums
* from each thread.
*/
static struct tr2_counter_block final_counter_block; /* access under tr2tls_mutex */
diff --git a/trace2/tr2_tls.h b/trace2/tr2_tls.h
index 3dfe6557fc..3bdbf4d275 100644
--- a/trace2/tr2_tls.h
+++ b/trace2/tr2_tls.h
@@ -11,7 +11,7 @@
*/
/*
- * Arbitry limit for thread names for column alignment.
+ * Arbitrary limit for thread names for column alignment.
*/
#define TR2_MAX_THREAD_NAME (24)
diff --git a/utf8.h b/utf8.h
index 35df76086a..cf8ecb0f21 100644
--- a/utf8.h
+++ b/utf8.h
@@ -33,8 +33,9 @@ char *reencode_string_len(const char *in, size_t insz,
const char *in_encoding,
size_t *outsz);
#else
-static inline char *reencode_string_len(const char *a, size_t b,
- const char *c, const char *d, size_t *e)
+static inline char *reencode_string_len(const char *a UNUSED, size_t b UNUSED,
+ const char *c UNUSED,
+ const char *d UNUSED, size_t *e)
{ if (e) *e = 0; return NULL; }
#endif