remote.c: remove braces from one-statement "for"-loops

Remove braces that don't follow the CodingGuidelines from code added
in fd3cb0501e (remote: move static variables into per-repository
struct, 2021-11-17). A subsequent commit will edit code adjacent to
this.

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Ævar Arnfjörð Bjarmason 2022-06-07 17:50:03 +02:00 committed by Junio C Hamano
parent e54793a95a
commit 338959da3e

View File

@ -144,14 +144,12 @@ static void remote_clear(struct remote *remote)
free((char *)remote->name);
free((char *)remote->foreign_vcs);
for (i = 0; i < remote->url_nr; i++) {
for (i = 0; i < remote->url_nr; i++)
free((char *)remote->url[i]);
}
FREE_AND_NULL(remote->pushurl);
for (i = 0; i < remote->pushurl_nr; i++) {
for (i = 0; i < remote->pushurl_nr; i++)
free((char *)remote->pushurl[i]);
}
FREE_AND_NULL(remote->pushurl);
free((char *)remote->receivepack);
free((char *)remote->uploadpack);
@ -2717,9 +2715,8 @@ void remote_state_clear(struct remote_state *remote_state)
{
int i;
for (i = 0; i < remote_state->remotes_nr; i++) {
for (i = 0; i < remote_state->remotes_nr; i++)
remote_clear(remote_state->remotes[i]);
}
FREE_AND_NULL(remote_state->remotes);
remote_state->remotes_alloc = 0;
remote_state->remotes_nr = 0;