From d1519aa012e8aa2aee0a77b6137c32abb66e77a8 Mon Sep 17 00:00:00 2001 From: mackarelfish Date: Sat, 30 May 2020 12:21:26 +0700 Subject: [PATCH] Fixed weird blocks behaviour with moving text --- dwmblocks.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dwmblocks.c b/dwmblocks.c index bf648c2..92e9570 100644 --- a/dwmblocks.c +++ b/dwmblocks.c @@ -75,7 +75,7 @@ void getcmd(const Block *block, char *output) return; char c; int i = strlen(block->icon); - fgets(output+i, CMDLENGTH-i, cmdf); + fgets(output+i, CMDLENGTH-2, cmdf); remove_all(output, '\n'); i = strlen(output); if (delim != '\0' && i)