patch 8.2.1595: cannot easily see what Vim sends to the terminal
Problem: Cannot easily see what Vim sends to the terminal.
Solution: Write output to the channel log if it contains terminal control
sequences. Avoid warnings for tputs() argument.
diff --git a/src/edit.c b/src/edit.c
index bc74f44..4115438 100644
--- a/src/edit.c
+++ b/src/edit.c
@@ -315,6 +315,9 @@
#endif
if (!p_ek)
{
+#ifdef FEAT_JOB_CHANNEL
+ ch_log_output = TRUE;
+#endif
// Disable bracketed paste mode, we won't recognize the escape
// sequences.
out_str(T_BD);
@@ -3724,6 +3727,9 @@
#endif
if (!p_ek)
{
+#ifdef FEAT_JOB_CHANNEL
+ ch_log_output = TRUE;
+#endif
// Re-enable bracketed paste mode.
out_str(T_BE);