diff options
author | Derrick Stolee <dstolee@microsoft.com> | 2018-06-27 09:24:40 -0400 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-06-27 10:29:10 -0700 |
commit | 88968ebf86d9b4524b17f6684dd8c67f0c6df652 (patch) | |
tree | fc84a4c4e7f94e5358bc481031b81d847f50a3f6 /commit-graph.c | |
parent | 1373e547f7d38b9444fcaae16c1de698b719aa15 (diff) | |
download | git-88968ebf86d9b4524b17f6684dd8c67f0c6df652.tar.gz |
commit-graph: verify commit date
Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'commit-graph.c')
-rw-r--r-- | commit-graph.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/commit-graph.c b/commit-graph.c index de656ebbaf..3ac28b5eb5 100644 --- a/commit-graph.c +++ b/commit-graph.c @@ -986,6 +986,12 @@ int verify_commit_graph(struct repository *r, struct commit_graph *g) oid_to_hex(&cur_oid), graph_commit->generation, max_generation + 1); + + if (graph_commit->date != odb_commit->date) + graph_report("commit date for commit %s in commit-graph is %"PRItime" != %"PRItime, + oid_to_hex(&cur_oid), + graph_commit->date, + odb_commit->date); } return verify_commit_graph_error; |