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:
authorKristian Høgsberg <krh@redhat.com>2007-09-18 04:06:45 +0400
committerJunio C Hamano <gitster@pobox.com>2007-09-27 11:33:33 +0400
commit6d69b6f6ac27ab6f71a10da34b813ca25fd2a358 (patch)
tree9e581e5453aa5b43109e5c2eed57e892352e1ac4 /builtin-tag.c
parenta9390b9fcefb18c4ccdb521086a051bc9112e03d (diff)
Clean up stripspace a bit, use strbuf even more.
Signed-off-by: Kristian Høgsberg <krh@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-tag.c')
-rw-r--r--builtin-tag.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/builtin-tag.c b/builtin-tag.c
index fcbf9bbf18..6132cac218 100644
--- a/builtin-tag.c
+++ b/builtin-tag.c
@@ -291,14 +291,11 @@ static void create_tag(const unsigned char *object, const char *tag,
free(path);
}
- strbuf_setlen(buf, stripspace(buf->buf, buf->len, 1));
+ stripspace(buf, 1);
if (!message && !buf->len)
die("no tag message?");
- /* insert the header and add the '\n' if needed: */
- if (buf->len)
- strbuf_addch(buf, '\n');
strbuf_insert(buf, 0, header_buf, header_len);
if (sign && do_sign(buf) < 0)