|
Karsten Hopp |
b3f1d2 |
To: vim-dev@vim.org
|
|
Karsten Hopp |
b3f1d2 |
Subject: Patch 7.1.184
|
|
Karsten Hopp |
b3f1d2 |
Fcc: outbox
|
|
Karsten Hopp |
b3f1d2 |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
b3f1d2 |
Mime-Version: 1.0
|
|
Karsten Hopp |
b3f1d2 |
Content-Type: text/plain; charset=ISO-8859-1
|
|
Karsten Hopp |
b3f1d2 |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
b3f1d2 |
------------
|
|
Karsten Hopp |
b3f1d2 |
|
|
Karsten Hopp |
b3f1d2 |
Patch 7.1.184
|
|
Karsten Hopp |
b3f1d2 |
Problem: Crash when deleting backwards over a line break in Insert mode.
|
|
Karsten Hopp |
b3f1d2 |
Solution: Don't advance the cursor when it's already on the NUL after a
|
|
Karsten Hopp |
b3f1d2 |
line. (Matthew Wozniski)
|
|
Karsten Hopp |
b3f1d2 |
Files: src/normal.c
|
|
Karsten Hopp |
b3f1d2 |
|
|
Karsten Hopp |
b3f1d2 |
|
|
Karsten Hopp |
b3f1d2 |
*** ../vim-7.1.183/src/normal.c Sun Oct 14 17:15:45 2007
|
|
Karsten Hopp |
b3f1d2 |
--- src/normal.c Tue Jan 1 16:40:24 2008
|
|
Karsten Hopp |
b3f1d2 |
***************
|
|
Karsten Hopp |
b3f1d2 |
*** 5849,5860 ****
|
|
Karsten Hopp |
b3f1d2 |
/* When the NL before the first char has to be deleted we
|
|
Karsten Hopp |
b3f1d2 |
* put the cursor on the NUL after the previous line.
|
|
Karsten Hopp |
b3f1d2 |
* This is a very special case, be careful!
|
|
Karsten Hopp |
b3f1d2 |
! * don't adjust op_end now, otherwise it won't work */
|
|
Karsten Hopp |
b3f1d2 |
if ( (cap->oap->op_type == OP_DELETE
|
|
Karsten Hopp |
b3f1d2 |
|| cap->oap->op_type == OP_CHANGE)
|
|
Karsten Hopp |
b3f1d2 |
&& !lineempty(curwin->w_cursor.lnum))
|
|
Karsten Hopp |
b3f1d2 |
{
|
|
Karsten Hopp |
b3f1d2 |
! ++curwin->w_cursor.col;
|
|
Karsten Hopp |
b3f1d2 |
cap->retval |= CA_NO_ADJ_OP_END;
|
|
Karsten Hopp |
b3f1d2 |
}
|
|
Karsten Hopp |
b3f1d2 |
continue;
|
|
Karsten Hopp |
b3f1d2 |
--- 5849,5861 ----
|
|
Karsten Hopp |
b3f1d2 |
/* When the NL before the first char has to be deleted we
|
|
Karsten Hopp |
b3f1d2 |
* put the cursor on the NUL after the previous line.
|
|
Karsten Hopp |
b3f1d2 |
* This is a very special case, be careful!
|
|
Karsten Hopp |
b3f1d2 |
! * Don't adjust op_end now, otherwise it won't work. */
|
|
Karsten Hopp |
b3f1d2 |
if ( (cap->oap->op_type == OP_DELETE
|
|
Karsten Hopp |
b3f1d2 |
|| cap->oap->op_type == OP_CHANGE)
|
|
Karsten Hopp |
b3f1d2 |
&& !lineempty(curwin->w_cursor.lnum))
|
|
Karsten Hopp |
b3f1d2 |
{
|
|
Karsten Hopp |
b3f1d2 |
! if (*ml_get_cursor() != NUL)
|
|
Karsten Hopp |
b3f1d2 |
! ++curwin->w_cursor.col;
|
|
Karsten Hopp |
b3f1d2 |
cap->retval |= CA_NO_ADJ_OP_END;
|
|
Karsten Hopp |
b3f1d2 |
}
|
|
Karsten Hopp |
b3f1d2 |
continue;
|
|
Karsten Hopp |
b3f1d2 |
*** ../vim-7.1.183/src/version.c Wed Jan 2 15:34:48 2008
|
|
Karsten Hopp |
b3f1d2 |
--- src/version.c Wed Jan 2 16:24:19 2008
|
|
Karsten Hopp |
b3f1d2 |
***************
|
|
Karsten Hopp |
b3f1d2 |
*** 668,669 ****
|
|
Karsten Hopp |
b3f1d2 |
--- 668,671 ----
|
|
Karsten Hopp |
b3f1d2 |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
b3f1d2 |
+ /**/
|
|
Karsten Hopp |
b3f1d2 |
+ 184,
|
|
Karsten Hopp |
b3f1d2 |
/**/
|
|
Karsten Hopp |
b3f1d2 |
|
|
Karsten Hopp |
b3f1d2 |
--
|
|
Karsten Hopp |
b3f1d2 |
Not too long ago, cut and paste was done with scissors and glue...
|
|
Karsten Hopp |
b3f1d2 |
|
|
Karsten Hopp |
b3f1d2 |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
b3f1d2 |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
b3f1d2 |
\\\ download, build and distribute -- http://www.A-A-P.org ///
|
|
Karsten Hopp |
b3f1d2 |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|