diff options
author | Bram Moolenaar <Bram@vim.org> | 2006-01-13 22:35:40 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2006-01-13 22:35:40 +0000 |
commit | a40ceaf88a6e2fbea7022dd84cd8dd5d903699e7 (patch) | |
tree | 204e108bdab14c1f09ce1746ac7b432f19fc5af7 /src/term.c | |
parent | 4770d09abd866bb53d95895dc6a5c5fe7cccb619 (diff) | |
download | vim-git-a40ceaf88a6e2fbea7022dd84cd8dd5d903699e7.tar.gz |
updated for version 7.0180v7.0180
Diffstat (limited to 'src/term.c')
-rw-r--r-- | src/term.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/term.c b/src/term.c index cc3c0365a..1f2753368 100644 --- a/src/term.c +++ b/src/term.c @@ -88,9 +88,6 @@ static void check_for_codes_from_term __ARGS((void)); || (defined(FEAT_MOUSE) && (!defined(UNIX) || defined(FEAT_MOUSE_XTERM))) static int get_bytes_from_buf __ARGS((char_u *, char_u *, int)); #endif -#ifdef FEAT_TERMRESPONSE -static void may_req_termresponse __ARGS((void)); -#endif static void del_termcode_idx __ARGS((int idx)); static int term_is_builtin __ARGS((char_u *name)); static int term_7to8bit __ARGS((char_u *p)); @@ -3249,11 +3246,13 @@ stoptermcap() } } -#ifdef FEAT_TERMRESPONSE +#if defined(FEAT_TERMRESPONSE) || defined(PROTO) /* * Request version string (for xterm) when needed. * Only do this after switching to raw mode, otherwise the result will be * echoed. + * Only do this after startup has finished, to avoid that the response comes + * while excuting "-c !cmd" or even after "-c quit". * Only do this after termcap mode has been started, otherwise the codes for * the cursor keys may be wrong. * Only do this when 'esckeys' is on, otherwise the response causes trouble in @@ -3262,17 +3261,18 @@ stoptermcap() * request to terminal while reading from a file). * The result is caught in check_termcode(). */ - static void + void may_req_termresponse() { if (crv_status == CRV_GET && cur_tmode == TMODE_RAW + && starting == 0 && termcap_active && p_ek -#ifdef UNIX +# ifdef UNIX && isatty(1) && isatty(read_cmd_fd) -#endif +# endif && *T_CRV != NUL) { out_str(T_CRV); |