LENGTH() has no negative effects because sizeof(char) == 1, but sizeof() makes the intention clear. --- src/command.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/command.c b/src/command.c index acdf994..ea9060c 100644 --- a/src/command.c +++ b/src/command.c @@ -571,7 +571,7 @@ struct wcd { /* window id completion data */ static void add_winid_completion(void* key, HSClient* client, struct wcd* data) { char buf[100]; - snprintf(buf, LENGTH(buf), "0x%lx", client->window); + snprintf(buf, sizeof(buf), "0x%lx", client->window); try_complete(data->needle, buf, data->output); } -- 1.8.5.3 -- + privacy is necessary + using gnupg http://gnupg.org + public key id: 0x92FEFDB7E44C32F9
Attachment:
signature.asc
Description: Digital signature