diff --git a/src/bin/termpty.c b/src/bin/termpty.c index 98240fb2..612c0e99 100644 --- a/src/bin/termpty.c +++ b/src/bin/termpty.c @@ -787,7 +787,7 @@ termpty_row_length(Termpty *ty, int y) ssize_t wret; Termcell *cells = termpty_cellrow_get(ty, y, &wret); - if (cells) + if (!cells) return 0; if (y >= 0) return termpty_line_length(cells, ty->w);