]> granicus.if.org Git - git/commitdiff
copy_msg(): rename to copy_reflog_msg()
authorDavid Turner <dturner@twopensource.com>
Tue, 10 Nov 2015 11:42:33 +0000 (12:42 +0100)
committerJeff King <peff@peff.net>
Fri, 20 Nov 2015 09:52:01 +0000 (04:52 -0500)
We will soon increase the visibility of this function, so make its name
more distinctive.

Signed-off-by: David Turner <dturner@twopensource.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Jeff King <peff@peff.net>
refs.c

diff --git a/refs.c b/refs.c
index ddcdf81fab9b86303241c3d292c9c81a8169863b..480de9ac92bbc7b48202ca3dd1029ab16a19b739 100644 (file)
--- a/refs.c
+++ b/refs.c
@@ -3287,7 +3287,7 @@ static int commit_ref(struct ref_lock *lock)
  * large, while cleaning up the whitespaces.  Especially, convert LF to space,
  * because reflog file is one line per entry.
  */
-static int copy_msg(char *buf, const char *msg)
+static int copy_reflog_msg(char *buf, const char *msg)
 {
        char *cp = buf;
        char c;
@@ -3391,7 +3391,7 @@ static int log_ref_write_fd(int fd, const unsigned char *old_sha1,
                        sha1_to_hex(new_sha1),
                        committer);
        if (msglen)
-               len += copy_msg(logrec + len - 1, msg) - 1;
+               len += copy_reflog_msg(logrec + len - 1, msg) - 1;
 
        written = len <= maxlen ? write_in_full(fd, logrec, len) : -1;
        free(logrec);