neovim segfaults after dismissing and reopening onscreen keyboard

If I open a particular file in neovim, scroll to the very last line, minimize termux and then open it, neovim segfaults. Consistently. I eliminated my configs as a reason.

What about dismissing and reopening the virtual keyboard that could cause a segfault? Is it possible to recreate those conditions on a PC? This is my main ask. I want to figure out if this is problem belongs to neovim, termux, or both.

Steps to reproduce:

Use the virtual keyboard for this.

  1. Paste into termux:
    curl -s https://termbin.com/2q2fq | nvim -u NONE -c "set linebreak"
    (You can copy the command from the 1st comment for convenience)
  2. Type
    G$
    (move the cursor to the end of the last line in the file)
  3. Dismiss the virtual keyboard (open the side menu and hit "keyboard")
  4. Bring the virtual keyboard back up (repeat prior step).
It looks like the bug is caused by the last line being wrapped and partially offscreen. So your terminal dimensions have to allow that.

Environment information:

Neovim version: 0.8.3
Termux version: 0.118.0
Android Version: 10
Terminal dimensions: 35 cols × 14 lines. (This has to do with line wrapping, if the line doesn't wrap, it won't work.)

Edit 1: Simplified reproduction steps. You don't have to paste commands into neovim anymore.
Edit 2: Added environment information section.
Edit 3: Changed mentions of suspending termux to dismissing the keyboard.
Was this page helpful?