Skip to contentSkip to conversation

Fix a few comments

PATCH New Elijah Newren via GitGitGadget 1 participant 3 messages Sep 19, 2021

lore
Share & tools
lore
#0 lore raw

cover Fix a few comments

Here's a couple trivial comment fixes sitting in random branches that I'm finally sending upstream.

Elijah Newren (2):
trace2.h: fix trivial comment typo
merge-ort: fix completely wrong comment

 merge-ort.c | 2 +-
 trace2.h    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

base-commit: 4c719308ce59dc70e606f910f40801f2c6051b24
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-1093%2Fnewren%2Ffix-comments-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-1093/newren/fix-comments-v1
Pull-Request: https://github.com/git/git/pull/1093

Signature · 1 line
gitgitgadget
#1 lore raw

PATCH 1/2 trace2.h: fix trivial comment typo

From: Elijah Newren <[email protected]>

---
 trace2.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
trace2.h +1 -1
index 9b7286c572f..2f450ab5bed 100644
@@ -350,7 +350,7 @@ void trace2_def_repo_fl(const char *file, int line, struct repository *repo);
  * being started, such as "read_recursive" or "do_read_index".
  *
  * The `repo` field, if set, will be used to get the "repo-id", so that
- * recursive oerations can be attributed to the correct repository.
+ * recursive operations can be attributed to the correct repository.
  */
 void trace2_region_enter_fl(const char *file, int line, const char *category,
 			    const char *label, const struct repository *repo, ...);
Signature · 1 line
gitgitgadget
#2 lore raw

PATCH 2/2 merge-ort: fix completely wrong comment

In reply to Elijah Newren via GitGitGadget

From: Elijah Newren <[email protected]>

Not sure what happened, but the comment is describing code elsewhere in the file. Fix the comment to actually discuss the code that follows.

---
 merge-ort.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
merge-ort.c +1 -1
index 515dc39b7f6..841196cf728 100644
@@ -4081,7 +4081,7 @@ static int record_conflicted_index_entries(struct merge_options *opt)
 	state.istate = index;
 	original_cache_nr = index->cache_nr;
 
-	/* Put every entry from paths into plist, then sort */
+	/* Append every entry from conflicted into index, then sort */
 	strmap_for_each_entry(&opt->priv->conflicted, &iter, e) {
 		const char *path = e->key;
 		struct conflict_info *ci = e->value;
Signature · 1 line
gitgitgadget