Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
sequencer: improve error message when an OID could not be parsed
author
Johannes Schindelin
<johannes.schindelin@gmx.de>
Wed, 13 Mar 2019 10:16:32 +0000
(
03:16
-0700)
committer
Junio C Hamano
<gitster@pobox.com>
Thu, 14 Mar 2019 03:46:29 +0000
(12:46 +0900)
The interactive rebase simply complains about an "invalid line" when the
object hash of, say, a `pick` line could not be parsed.
Let's tell the user what happened in a little more detail.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
sequencer.c
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(from parent 1:
26527ed
)
diff --git
a/sequencer.c
b/sequencer.c
index 95dda23eee450d1d60a70434d254071c6c05146b..f91062718dd9ddfbf9e49ad2844485edeb1af1a8 100644
(file)
--- a/
sequencer.c
+++ b/
sequencer.c
@@
-2137,7
+2137,8
@@
static int parse_insn_line(struct repository *r, struct todo_item *item,
item->arg_len = (int)(eol - item->arg);
if (status < 0)
- return -1;
+ return error(_("could not parse '%.*s'"),
+ (int)(end_of_object_name - bol), bol);
item->commit = lookup_commit_reference(r, &commit_oid);
return !item->commit;