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>2020-08-20 02:14:48 +0300
committerJunio C Hamano <gitster@pobox.com>2020-08-20 02:14:48 +0300
commit4499a42d0cb774c1ed6953d03226b7cbe0756af7 (patch)
tree6a548106ec6d081166b5b20480887b4b97249a09 /sequencer.c
parent6cceea19eb6b86a4a293c92fe9653ccc8bb71526 (diff)
parent5da69c0dacb65cf80fc80b53e652fefad7469bf1 (diff)
Merge branch 'ak/sequencer-fix-find-uniq-abbrev'
Ring buffer with size 4 used for bin-hex translation resulted in a wrong object name in the sequencer's todo output, which has been corrected. * ak/sequencer-fix-find-uniq-abbrev: rebase -i: fix possibly wrong onto hash in todo
Diffstat (limited to 'sequencer.c')
-rw-r--r--sequencer.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sequencer.c b/sequencer.c
index 8a25e28cad..2425896911 100644
--- a/sequencer.c
+++ b/sequencer.c
@@ -5178,13 +5178,14 @@ int complete_action(struct repository *r, struct replay_opts *opts, unsigned fla
struct string_list *commands, unsigned autosquash,
struct todo_list *todo_list)
{
- const char *shortonto, *todo_file = rebase_path_todo();
+ char shortonto[GIT_MAX_HEXSZ + 1];
+ const char *todo_file = rebase_path_todo();
struct todo_list new_todo = TODO_LIST_INIT;
struct strbuf *buf = &todo_list->buf, buf2 = STRBUF_INIT;
struct object_id oid = onto->object.oid;
int res;
- shortonto = find_unique_abbrev(&oid, DEFAULT_ABBREV);
+ find_unique_abbrev_r(shortonto, &oid, DEFAULT_ABBREV);
if (buf->len == 0) {
struct todo_item *item = append_new_todo(todo_list);