git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] name-rev: change ULONG_MAX to TIME_MAX

From
Michael J Gruber <git@grubix.eu>
Date
Aug 30, 2017, 09:46 UTC
Message-ID
<ef9aebb63227c36b8b72a65240a416a0271cc618.1504086318.git.git@grubix.eu>

Earlier, dddbad728c ("timestamp_t: a new data type for timestamps", 2017-04-26) changed several types to timestamp_t.

5589e87fd8 ("name-rev: change a "long" variable to timestamp_t", 2017-05-20) cleaned up a missed variable, but both missed a _MAX constant.

Change the remaining constant to the one appropriate for the current type

Signed-off-by: Michael J Gruber <git@grubix.eu>
---
 builtin/name-rev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/builtin/name-rev.c b/builtin/name-rev.c
index c41ea7c2a6..598da6c8bc 100644
--- a/builtin/name-rev.c
+++ b/builtin/name-rev.c
@@ -253,7 +253,7 @@ static int name_ref(const char *path, const struct object_id *oid, int flags, vo
 		struct commit *commit = (struct commit *)o;
 		int from_tag = starts_with(path, "refs/tags/");
 
-		if (taggerdate == ULONG_MAX)
+		if (taggerdate == TIME_MAX)
 			taggerdate = ((struct commit *)o)->date;
 		path = name_ref_abbrev(path, can_abbreviate_output);
 		name_rev(commit, xstrdup(path), taggerdate, 0, 0,
-- 
2.14.1.603.gf58147c36e
Next: Johannes Schindelin
Message 1 of 14 in “name-rev: change ULONG_MAX to TIME_MAX”
  1. name-rev: change ULONG_MAX to TIME_MAXMichael J Gruber, Aug 30, 2017
  2. Johannes SchindelinAug 30, 2017
  3. Junio C HamanoSep 6, 2017
  4. Michael J GruberSep 6, 2017
  5. Jeff KingSep 6, 2017
  6. Michael J GruberSep 7, 2017
  7. 2/4 t6120: test name-rev --all and --stdinMichael J Gruber, Sep 7, 2017
  8. 4/4 t6120: test describe and name-rev with deep reposMichael J Gruber, Sep 7, 2017
  9. 1/4 t7004: move limited stack prereq to test-libMichael J Gruber, Sep 7, 2017
  10. 3/4 t6120: clean up state after breaking repoMichael J Gruber, Sep 7, 2017
  11. 0/4 Test name-rev with small stackMichael J Gruber, Sep 7, 2017
  12. Jeff KingSep 7, 2017
  13. Michael J GruberSep 8, 2017
  14. Jeff KingSep 11, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.