Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2023-08-24 23:54:54 +0300
committerJunio C Hamano <gitster@pobox.com>2023-08-25 22:01:09 +0300
commitd28eb5e4f04d589dde16be9880d8e475f9517a95 (patch)
treef98b79463ce28a7dac5efb24b8c38b68758ec541 /rerere.c
parentd63a9e201acb1c81c58351cc6bdb042de0111697 (diff)
rerere: fix comment on handle_file() helper
The return value from handle_path() is returned to the caller of handle_file() in the normal cases, and it is not the number of hunks. It is just a normal C Boolean, "do we (!=0) or do we not (0) have conflict?" plus "a negative return value signals an error". And all the callers of handle_file() understands its return value as such. Update the comment to match the reality after 221444f5 (rerere: only return whether a path has conflicts or not, 2018-08-05), which apparently forgot to update this comment when it turned the returned value of this function from the number of conflict hunks to a boolean plus error. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'rerere.c')
-rw-r--r--rerere.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/rerere.c b/rerere.c
index 73cdc8392f..4ce1270a94 100644
--- a/rerere.c
+++ b/rerere.c
@@ -454,7 +454,7 @@ static int handle_path(unsigned char *hash, struct rerere_io *io, int marker_siz
/*
* Scan the path for conflicts, do the "handle_path()" thing above, and
- * return the number of conflict hunks found.
+ * return true iff conflict hunks were found.
*/
static int handle_file(struct index_state *istate,
const char *path, unsigned char *hash, const char *output)