From: Stefan Beller Date: Thu, 18 Jul 2013 21:35:27 GMT Subject: [PATCH 3/3] apply, find_name_traditional: Do not initialize len to the lines length. Message-ID: <1374183327-14939-3-git-send-email-stefanbeller@googlemail.com> In-Reply-To: <1374183327-14939-1-git-send-email-stefanbeller@googlemail.com> The variable len is set to len = strchrnul(line, '\n') - line; unconditionally 9 lines later, hence we can remove the call to strlen. Signed-off-by: Stefan Beller --- builtin/apply.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/apply.c b/builtin/apply.c index 1218688..681a40b 100644 --- a/builtin/apply.c +++ b/builtin/apply.c @@ -722,7 +722,7 @@ static char *find_name(const char *line, char *def, int p_value, int terminate) static char *find_name_traditional(const char *line, char *def, int p_value) { - size_t len = strlen(line); + size_t len; size_t date_len; if (*line == '"') { -- 1.8.3.3.754.g9c3c367.dirty