diff options
Diffstat (limited to 'swaybar/status_line.c')
-rw-r--r-- | swaybar/status_line.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/swaybar/status_line.c b/swaybar/status_line.c index c94ac6d4..cc7e217f 100644 --- a/swaybar/status_line.c +++ b/swaybar/status_line.c | |||
@@ -17,13 +17,13 @@ void status_error(struct status_line *status, const char *text) { | |||
17 | status->text = text; | 17 | status->text = text; |
18 | } | 18 | } |
19 | 19 | ||
20 | bool handle_status_readable(struct status_line *status) { | 20 | bool status_handle_readable(struct status_line *status) { |
21 | char *line; | 21 | char *line; |
22 | switch (status->protocol) { | 22 | switch (status->protocol) { |
23 | case PROTOCOL_ERROR: | 23 | case PROTOCOL_ERROR: |
24 | return false; | 24 | return false; |
25 | case PROTOCOL_I3BAR: | 25 | case PROTOCOL_I3BAR: |
26 | if (i3bar_readable(status) > 0) { | 26 | if (i3bar_handle_readable(status) > 0) { |
27 | return true; | 27 | return true; |
28 | } | 28 | } |
29 | break; | 29 | break; |
@@ -66,6 +66,7 @@ bool handle_status_readable(struct status_line *status) { | |||
66 | 66 | ||
67 | status->protocol = PROTOCOL_I3BAR; | 67 | status->protocol = PROTOCOL_I3BAR; |
68 | free(status->text_state.buffer); | 68 | free(status->text_state.buffer); |
69 | wl_list_init(&status->blocks); | ||
69 | status->i3bar_state.buffer_size = 4096; | 70 | status->i3bar_state.buffer_size = 4096; |
70 | status->i3bar_state.buffer = | 71 | status->i3bar_state.buffer = |
71 | malloc(status->i3bar_state.buffer_size); | 72 | malloc(status->i3bar_state.buffer_size); |