Mercurial > vim
comparison src/normal.c @ 30471:584231b9b37e v9.0.0571
patch 9.0.0571: MS-Windows: CTRL-C can make Vim exit
Commit: https://github.com/vim/vim/commit/f7e7302acb20b6ef6caa0740da1450b677ac91fb
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat Sep 24 13:10:04 2022 +0100
patch 9.0.0571: MS-Windows: CTRL-C can make Vim exit
Problem: MS-Windows: CTRL-C can make Vim exit.
Solution: Check the not-a-term argument.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 24 Sep 2022 14:15:04 +0200 |
parents | 072c61082148 |
children | eb86a6330ae3 |
comparison
equal
deleted
inserted
replaced
30470:1c95c2c45126 | 30471:584231b9b37e |
---|---|
6791 && cmdwin_type == 0 | 6791 && cmdwin_type == 0 |
6792 #endif | 6792 #endif |
6793 && !VIsual_active | 6793 && !VIsual_active |
6794 && no_reason) | 6794 && no_reason) |
6795 { | 6795 { |
6796 int out_redir = !stdout_isatty | 6796 int out_redir = !stdout_isatty && !is_not_a_term_or_gui(); |
6797 #ifdef FEAT_GUI | 6797 |
6798 && !gui.in_use | |
6799 #endif | |
6800 ; | |
6801 // The user may accidentally do "vim file | grep word" and then | 6798 // The user may accidentally do "vim file | grep word" and then |
6802 // CTRL-C doesn't show anything. With a changed buffer give the | 6799 // CTRL-C doesn't show anything. With a changed buffer give the |
6803 // message on stderr. Without any changes might as well exit. | 6800 // message on stderr. Without any changes might as well exit. |
6804 if (anyBufIsChanged()) | 6801 if (anyBufIsChanged()) |
6805 { | 6802 { |