diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2017-10-25 17:13:46 +0200 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2017-10-31 17:25:23 +0100 |
commit | 7491cd4c22601eb0c3bedfea740f2aec3b8372ed (patch) | |
tree | e5b8c3adf9e17e9abf3c028ea163ee7840659826 /src/tools/config.c | |
parent | peer: store total number of peers instead of iterating (diff) | |
download | wireguard-monolithic-historical-7491cd4c22601eb0c3bedfea740f2aec3b8372ed.tar.xz wireguard-monolithic-historical-7491cd4c22601eb0c3bedfea740f2aec3b8372ed.zip |
global: infuriating kernel iterator style
One types:
for (i = 0 ...
So one should also type:
for_each_obj (obj ...
But the upstream kernel style guidelines are insane, and so we must
instead do:
for_each_obj(obj ...
Ugly, but one must choose his battles wisely.
Diffstat (limited to 'src/tools/config.c')
-rw-r--r-- | src/tools/config.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/config.c b/src/tools/config.c index ec16e26..8fe3e1c 100644 --- a/src/tools/config.c +++ b/src/tools/config.c @@ -384,7 +384,7 @@ bool config_read_init(struct config_ctx *ctx, bool append) struct wgdevice *config_read_finish(struct config_ctx *ctx) { struct wgpeer *peer; - for_each_wgpeer (ctx->device, peer) { + for_each_wgpeer(ctx->device, peer) { if (key_is_zero(peer->public_key)) { fprintf(stderr, "A peer is missing a public key\n"); goto err; |