Fix invalid read in titlebar

This commit is contained in:
Michael Vetter
2020-05-24 13:47:21 +02:00
parent a2af4c3184
commit 090732ed96

View File

@@ -197,9 +197,10 @@ _title_bar_draw(void)
char *title = win_get_title(current);
mvwprintw(win, 0, 0, " %s", title);
free(title);
pos = strlen(title) + 1;
free(title);
// presence is written from the right side
// calculate it first so we have a maxposition
maxrightpos = _show_self_presence();