aboutsummaryrefslogtreecommitdiffstats
path: root/sequencer.h
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2018-09-17 13:53:54 -0700
committerJunio C Hamano <gitster@pobox.com>2018-09-17 13:53:54 -0700
commitfba9654364a523bf146df26052ab05dd52c1d719 (patch)
treecf422aabddfa4c12069785a086e426a971e1ebe6 /sequencer.h
parent30035d1d60053e2999041ca14ab607d40206e201 (diff)
parent66e83d9b41f7438cb167b9bb54093ebbf0532437 (diff)
downloadgit-fba9654364a523bf146df26052ab05dd52c1d719.tar.gz
Merge branch 'jk/trailer-fixes'
"git interpret-trailers" and its underlying machinery had a buggy code that attempted to ignore patch text after commit log message, which triggered in various codepaths that will always get the log message alone and never get such an input. * jk/trailer-fixes: append_signoff: use size_t for string offsets sequencer: ignore "---" divider when parsing trailers pretty, ref-filter: format %(trailers) with no_divider option interpret-trailers: allow suppressing "---" divider interpret-trailers: tighten check for "---" patch boundary trailer: pass process_trailer_opts to trailer_info_get() trailer: use size_t for iterating trailer list trailer: use size_t for string offsets
Diffstat (limited to 'sequencer.h')
-rw-r--r--sequencer.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/sequencer.h b/sequencer.h
index c751c9d6e4..c986bc8251 100644
--- a/sequencer.h
+++ b/sequencer.h
@@ -90,7 +90,14 @@ int rearrange_squash(void);
extern const char sign_off_header[];
-void append_signoff(struct strbuf *msgbuf, int ignore_footer, unsigned flag);
+/*
+ * Append a signoff to the commit message in "msgbuf". The ignore_footer
+ * parameter specifies the number of bytes at the end of msgbuf that should
+ * not be considered at all. I.e., they are not checked for existing trailers,
+ * and the new signoff will be spliced into the buffer before those bytes.
+ */
+void append_signoff(struct strbuf *msgbuf, size_t ignore_footer, unsigned flag);
+
void append_conflicts_hint(struct strbuf *msgbuf);
int message_is_empty(const struct strbuf *sb,
enum commit_msg_cleanup_mode cleanup_mode);