diff --git a/src/nano.c b/src/nano.c
index 7f94cfaf7be154f7642c797e330c1b24e5464a26..2e9f84448cba3e600611b1c64a305526f48e94d5 100644
--- a/src/nano.c
+++ b/src/nano.c
@@ -2223,9 +2223,6 @@ int main(int argc, char **argv)
     while (TRUE) {
 	bool meta_key, func_key, s_or_t, ran_func, finished;
 
-	/* Make sure the statusbar cursor position is reset. */
-	do_prompt_abort();
-
 	/* Make sure the cursor is in the edit window. */
 	reset_cursor();
 
@@ -2240,6 +2237,10 @@ int main(int argc, char **argv)
 	}
 #endif
 
+	/* Just in case we were at the statusbar prompt, make sure the
+	 * statusbar cursor position is reset. */
+	do_prompt_abort();
+
 	/* If constant cursor position display is on, and there are no
 	 * keys waiting in the input buffer, display the current cursor
 	 * position on the statusbar. */