mirror of
https://github.com/tmux/tmux.git
synced 2026-07-09 02:49:30 +00:00
Check for width/height 0, based on change from Uzair Aftab.
This commit is contained in:
@@ -834,6 +834,11 @@ mode_tree_draw(struct mode_tree_data *mtd)
|
||||
if (mtd->line_size == 0)
|
||||
return;
|
||||
|
||||
w = mtd->width;
|
||||
h = mtd->height;
|
||||
if (w == 0 || h == 0)
|
||||
return;
|
||||
|
||||
memcpy(&gc0, &grid_default_cell, sizeof gc0);
|
||||
memcpy(&gc, &grid_default_cell, sizeof gc);
|
||||
style_apply(&gc, oo, "tree-mode-selection-style", NULL);
|
||||
@@ -843,9 +848,6 @@ mode_tree_draw(struct mode_tree_data *mtd)
|
||||
dfg = gc.fg;
|
||||
dfg0 = gc0.fg;
|
||||
|
||||
w = mtd->width;
|
||||
h = mtd->height;
|
||||
|
||||
screen_write_start(&ctx, s);
|
||||
screen_write_clearscreen(&ctx, 8);
|
||||
ft = format_create_defaults(NULL, NULL, NULL, NULL, wp);
|
||||
|
||||
Reference in New Issue
Block a user