swaybar: correctly render min_width for strings

fixes #1635
This commit is contained in:
Jonathan Rouleau 2018-03-27 01:14:03 +00:00
parent 45f14fcb24
commit 54444e7587
3 changed files with 9 additions and 2 deletions

View file

@ -121,7 +121,7 @@ static void parse_json(struct bar *bar, const char *text) {
new->min_width = json_object_get_int(min_width);
} else if (type == json_type_string) {
/* the width will be calculated when rendering */
new->min_width = 0;
new->min_width_str = strdup(json_object_get_string(min_width));
}
}