From: Junio C Hamano <gitster@pobox.com>
To: git@vger.kernel.org
Subject: [PATCH 1/2] mailmap: fix bogus for() loop that happened to be safe by accident
Date: Fri, 7 Dec 2007 17:32:52 -0800 [thread overview]
Message-ID: <1197077573-14945-1-git-send-email-gitster@pobox.com> (raw)
The empty loop pretended to have an empty statement as its body by a
phony indentation, but in fact was slurping the next statement into it.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
mailmap.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/mailmap.c b/mailmap.c
index 8714167..f017255 100644
--- a/mailmap.c
+++ b/mailmap.c
@@ -42,9 +42,10 @@ int read_mailmap(struct path_list *map, const char *filename, char **repo_abbrev
continue;
if (right_bracket == left_bracket + 1)
continue;
- for (end_of_name = left_bracket; end_of_name != buffer
- && isspace(end_of_name[-1]); end_of_name--)
- /* keep on looking */
+ for (end_of_name = left_bracket;
+ end_of_name != buffer && isspace(end_of_name[-1]);
+ end_of_name--)
+ ; /* keep on looking */
if (end_of_name == buffer)
continue;
name = xmalloc(end_of_name - buffer + 1);
--
1.5.3.7-2182-g108b
next reply other threads:[~2007-12-08 1:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-08 1:32 Junio C Hamano [this message]
2007-12-08 1:32 ` [PATCH 2/2] shortlog: code restruturing and clean-up Junio C Hamano
2007-12-08 9:34 ` Wincent Colaiuta
2007-12-08 17:13 ` Alex Riesen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1197077573-14945-1-git-send-email-gitster@pobox.com \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).