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:
authorJeff King <peff@peff.net>2020-07-28 23:26:31 +0300
committerJunio C Hamano <gitster@pobox.com>2020-07-29 01:02:18 +0300
commitf6d8942b1fc6c968980c8ae03054d7b2114b4415 (patch)
treeded3f10f7d390a4dba264c70197b00bc327fae40 /daemon.c
parentc972bf4cf546a56fe1c54ddde1d33ebb9f454a0f (diff)
strvec: fix indentation in renamed calls
Code which split an argv_array call across multiple lines, like: argv_array_pushl(&args, "one argument", "another argument", "and more", NULL); was recently mechanically renamed to use strvec, which results in mis-matched indentation like: strvec_pushl(&args, "one argument", "another argument", "and more", NULL); Let's fix these up to align the arguments with the opening paren. I did this manually by sifting through the results of: git jump grep 'strvec_.*,$' and liberally applying my editor's auto-format. Most of the changes are of the form shown above, though I also normalized a few that had originally used a single-tab indentation (rather than our usual style of aligning with the open paren). I also rewrapped a couple of obvious cases (e.g., where previously too-long lines became short enough to fit on one), but I wasn't aggressive about it. In cases broken to three or more lines, the grouping of arguments is sometimes meaningful, and it wasn't worth my time or reviewer time to ponder each case individually. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'daemon.c')
-rw-r--r--daemon.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/daemon.c b/daemon.c
index cea5f5354f..0dec89fa02 100644
--- a/daemon.c
+++ b/daemon.c
@@ -665,7 +665,7 @@ static void parse_extra_args(struct hostinfo *hi, struct strvec *env,
if (git_protocol.len > 0) {
loginfo("Extended attribute \"protocol\": %s", git_protocol.buf);
strvec_pushf(env, GIT_PROTOCOL_ENVIRONMENT "=%s",
- git_protocol.buf);
+ git_protocol.buf);
}
strbuf_release(&git_protocol);
}
@@ -915,7 +915,7 @@ static void handle(int incoming, struct sockaddr *addr, socklen_t addrlen)
inet_ntop(addr->sa_family, &sin_addr->sin_addr, buf, sizeof(buf));
strvec_pushf(&cld.env_array, "REMOTE_ADDR=%s", buf);
strvec_pushf(&cld.env_array, "REMOTE_PORT=%d",
- ntohs(sin_addr->sin_port));
+ ntohs(sin_addr->sin_port));
#ifndef NO_IPV6
} else if (addr->sa_family == AF_INET6) {
char buf[128] = "";
@@ -923,7 +923,7 @@ static void handle(int incoming, struct sockaddr *addr, socklen_t addrlen)
inet_ntop(AF_INET6, &sin6_addr->sin6_addr, buf, sizeof(buf));
strvec_pushf(&cld.env_array, "REMOTE_ADDR=[%s]", buf);
strvec_pushf(&cld.env_array, "REMOTE_PORT=%d",
- ntohs(sin6_addr->sin6_port));
+ ntohs(sin6_addr->sin6_port));
#endif
}