display: don't show the cursor while we are busy calculating its position

This fixes https://savannah.gnu.org/bugs/?51134.
This commit is contained in:
Benno Schulenberg 2017-05-29 21:12:25 +02:00
parent 4781d4d351
commit cfa20c3f42

View File

@ -3184,6 +3184,9 @@ void do_cursorpos(bool force)
assert(openfile->fileage != NULL && openfile->current != NULL);
/* Hide the cursor while we are calculating. */
curs_set(0);
/* Determine the size of the file up to the cursor. */
saved_byte = openfile->current->data[openfile->current_x];
openfile->current->data[openfile->current_x] = '\0';