a11y: Fix a crash at text deletion

https://bugzilla.gnome.org/show_bug.cgi?id=727587