|
Karsten Hopp |
21a594 |
To: vim_dev@googlegroups.com
|
|
Karsten Hopp |
21a594 |
Subject: Patch 7.3.168
|
|
Karsten Hopp |
21a594 |
Fcc: outbox
|
|
Karsten Hopp |
21a594 |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
21a594 |
Mime-Version: 1.0
|
|
Karsten Hopp |
21a594 |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
21a594 |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
21a594 |
------------
|
|
Karsten Hopp |
21a594 |
|
|
Karsten Hopp |
21a594 |
Patch 7.3.168
|
|
Karsten Hopp |
21a594 |
Problem: When the second argument of input() contains a CR the text up to
|
|
Karsten Hopp |
21a594 |
that is used without asking the user. (Yasuhiro Matsumoto)
|
|
Karsten Hopp |
21a594 |
Solution: Change CR, NL and ESC in the text to a space.
|
|
Karsten Hopp |
21a594 |
Files: src/getchar.c
|
|
Karsten Hopp |
21a594 |
|
|
Karsten Hopp |
21a594 |
|
|
Karsten Hopp |
21a594 |
*** ../vim-7.3.167/src/getchar.c 2011-03-22 13:07:19.000000000 +0100
|
|
Karsten Hopp |
21a594 |
--- src/getchar.c 2011-04-28 14:50:26.000000000 +0200
|
|
Karsten Hopp |
21a594 |
***************
|
|
Karsten Hopp |
21a594 |
*** 635,645 ****
|
|
Karsten Hopp |
21a594 |
--- 635,648 ----
|
|
Karsten Hopp |
21a594 |
/*
|
|
Karsten Hopp |
21a594 |
* Stuff "s" into the stuff buffer, leaving special key codes unmodified and
|
|
Karsten Hopp |
21a594 |
* escaping other K_SPECIAL and CSI bytes.
|
|
Karsten Hopp |
21a594 |
+ * Change CR, LF and ESC into a space.
|
|
Karsten Hopp |
21a594 |
*/
|
|
Karsten Hopp |
21a594 |
void
|
|
Karsten Hopp |
21a594 |
stuffReadbuffSpec(s)
|
|
Karsten Hopp |
21a594 |
char_u *s;
|
|
Karsten Hopp |
21a594 |
{
|
|
Karsten Hopp |
21a594 |
+ int c;
|
|
Karsten Hopp |
21a594 |
+
|
|
Karsten Hopp |
21a594 |
while (*s != NUL)
|
|
Karsten Hopp |
21a594 |
{
|
|
Karsten Hopp |
21a594 |
if (*s == K_SPECIAL && s[1] != NUL && s[2] != NUL)
|
|
Karsten Hopp |
21a594 |
***************
|
|
Karsten Hopp |
21a594 |
*** 649,659 ****
|
|
Karsten Hopp |
21a594 |
s += 3;
|
|
Karsten Hopp |
21a594 |
}
|
|
Karsten Hopp |
21a594 |
else
|
|
Karsten Hopp |
21a594 |
#ifdef FEAT_MBYTE
|
|
Karsten Hopp |
21a594 |
! stuffcharReadbuff(mb_ptr2char_adv(&s);;
|
|
Karsten Hopp |
21a594 |
#else
|
|
Karsten Hopp |
21a594 |
! stuffcharReadbuff(*s++);
|
|
Karsten Hopp |
21a594 |
#endif
|
|
Karsten Hopp |
21a594 |
}
|
|
Karsten Hopp |
21a594 |
}
|
|
Karsten Hopp |
21a594 |
#endif
|
|
Karsten Hopp |
21a594 |
--- 652,667 ----
|
|
Karsten Hopp |
21a594 |
s += 3;
|
|
Karsten Hopp |
21a594 |
}
|
|
Karsten Hopp |
21a594 |
else
|
|
Karsten Hopp |
21a594 |
+ {
|
|
Karsten Hopp |
21a594 |
#ifdef FEAT_MBYTE
|
|
Karsten Hopp |
21a594 |
! c = mb_ptr2char_adv(&s);
|
|
Karsten Hopp |
21a594 |
#else
|
|
Karsten Hopp |
21a594 |
! c = *s++;
|
|
Karsten Hopp |
21a594 |
#endif
|
|
Karsten Hopp |
21a594 |
+ if (c == CAR || c == NL || c == ESC)
|
|
Karsten Hopp |
21a594 |
+ c = ' ';
|
|
Karsten Hopp |
21a594 |
+ stuffcharReadbuff(c);
|
|
Karsten Hopp |
21a594 |
+ }
|
|
Karsten Hopp |
21a594 |
}
|
|
Karsten Hopp |
21a594 |
}
|
|
Karsten Hopp |
21a594 |
#endif
|
|
Karsten Hopp |
21a594 |
*** ../vim-7.3.167/src/version.c 2011-04-28 17:27:05.000000000 +0200
|
|
Karsten Hopp |
21a594 |
--- src/version.c 2011-04-28 17:28:36.000000000 +0200
|
|
Karsten Hopp |
21a594 |
***************
|
|
Karsten Hopp |
21a594 |
*** 716,717 ****
|
|
Karsten Hopp |
21a594 |
--- 716,719 ----
|
|
Karsten Hopp |
21a594 |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
21a594 |
+ /**/
|
|
Karsten Hopp |
21a594 |
+ 168,
|
|
Karsten Hopp |
21a594 |
/**/
|
|
Karsten Hopp |
21a594 |
|
|
Karsten Hopp |
21a594 |
--
|
|
Karsten Hopp |
21a594 |
Everyone has a photographic memory. Some don't have film.
|
|
Karsten Hopp |
21a594 |
|
|
Karsten Hopp |
21a594 |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
21a594 |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
21a594 |
\\\ an exciting new programming language -- http://www.Zimbu.org ///
|
|
Karsten Hopp |
21a594 |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|