sway

i3-compatible Wayland compositor
git clone https://git.awy.one/sway
Log | Files | Refs | README | LICENSE

commit 5587af1782539e2ea2c762597054a066bc0eeee7
parent b9726afd485a9eca0aa7d123db1e55edb7bfc386
Author: Geoff Greer <geoff@greer.fm>
Date:   Thu, 26 Apr 2018 18:16:29 -0700

Rename len to msg_len. Avoids an aliased variable that was a little confusing to follow.

Diffstat:
Msway/config/bar.c | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/sway/config/bar.c b/sway/config/bar.c @@ -173,9 +173,9 @@ void invoke_swaybar(struct bar_config *bar) { char *command = malloc(len + 1); if (!command) { const char msg[] = "Unable to allocate swaybar command string"; - size_t len = sizeof(msg); - if (write(filedes[1], &len, sizeof(int))) {}; - if (write(filedes[1], msg, len)) {}; + size_t msg_len = sizeof(msg); + if (write(filedes[1], &msg_len, sizeof(int))) {}; + if (write(filedes[1], msg, msg_len)) {}; close(filedes[1]); exit(1); }