Fix logic error in Cursor::next
Fix logic error in Cursor::next

It was missing the end of the rope in cases where the tree was large.

Fixes #1062

google/xi-editor,google/xi-editor,google/xi-editor,google/xi-editor