Fix search freezing Alacritty
Fix search freezing Alacritty

This resolves a regression introduced in 530de00 where searching would
cause a deadlock when the viewport is at the bottom of the scrollback
and a match ends in the last cell.

Fixes #4800.
alacritty/alacritty,jwilm/alacritty,jwilm/alacritty,alacritty/alacritty,jwilm/alacritty,jwilm/alacritty