diff src/message.c @ 29734:2d2f36e430f9 v9.0.0207

patch 9.0.0207: stacktrace not shown when debugging Commit: https://github.com/vim/vim/commit/28c162f6f1f525882a9a60f10ab4836dee7eb59f Author: zeertzjq <zeertzjq@outlook.com> Date: Sun Aug 14 14:49:50 2022 +0100 patch 9.0.0207: stacktrace not shown when debugging Problem: Stacktrace not shown when debugging. Solution: Set msg_scroll in msg_source(). (closes https://github.com/vim/vim/issues/10917)
author Bram Moolenaar <Bram@vim.org>
date Sun, 14 Aug 2022 16:00:03 +0200
parents 89e1d67814a9
children 455e7588b979
line wrap: on
line diff
--- a/src/message.c
+++ b/src/message.c
@@ -531,6 +531,7 @@ msg_source(int attr)
 	return;
     recursive = TRUE;
 
+    msg_scroll = TRUE;  // this will take more than one line
     ++no_wait_return;
     p = get_emsg_source();
     if (p != NULL)
@@ -746,7 +747,6 @@ emsg_core(char_u *s)
     }
 
     emsg_on_display = TRUE;	// remember there is an error message
-    ++msg_scroll;		// don't overwrite a previous message
     attr = HL_ATTR(HLF_E);	// set highlight mode for error messages
     if (msg_scrolled != 0)
 	need_wait_return = TRUE;    // needed in case emsg() is called after
@@ -759,6 +759,7 @@ emsg_core(char_u *s)
 #endif
     /*
      * Display name and line number for the source of the error.
+     * Sets "msg_scroll".
      */
     msg_source(attr);