diff options
Diffstat (limited to 'swaynag')
-rw-r--r-- | swaynag/config.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/swaynag/config.c b/swaynag/config.c index 40f3f65e..200611f4 100644 --- a/swaynag/config.c +++ b/swaynag/config.c @@ -348,6 +348,10 @@ int swaynag_load_config(char *path, struct swaynag *swaynag, list_t *types) { continue; } + if (line[nread - 1] == '\n') { + line[nread - 1] = '\0'; + } + if (line[0] == '[') { char *close = strchr(line, ']'); if (!close) { |