home *** CD-ROM | disk | FTP | other *** search
/ vim.ftp.fu-berlin.de / 2015-02-03.vim.ftp.fu-berlin.de.tar / vim.ftp.fu-berlin.de / patches / 6.0.153 < prev    next >
Encoding:
Internet Message Format  |  2002-01-27  |  2.0 KB

  1. To: vim-dev@vim.org
  2. Subject: Patch 6.0.153
  3. Fcc: outbox
  4. From: Bram Moolenaar <Bram@moolenaar.net>
  5. MIME-Version: 1.0
  6. Content-Type: text/plain; charset=ISO-8859-1
  7. Content-Transfer-Encoding: 8bit
  8. ------------
  9.  
  10. Patch 6.0.153
  11. Problem:    When using (illegal) double-byte characters and Vim syntax
  12.         highlighting Vim can crash. (Yasuhiro Matsumoto)
  13. Solution:   Increase a pointer over a character instead of a byte.
  14. Files:        src/regexp.c
  15.  
  16.  
  17. *** ../vim60.152/src/regexp.c    Tue Jan 22 17:42:37 2002
  18. --- src/regexp.c    Mon Jan 28 14:01:09 2002
  19. ***************
  20. *** 3904,3909 ****
  21. --- 3904,3912 ----
  22.                   /* backup to last char of previous line */
  23.                   --reglnum;
  24.                   regline = reg_getline(reglnum);
  25. +                 /* Just in case regrepeat() didn't count right. */
  26. +                 if (regline == NULL)
  27. +                 return FALSE;
  28.                   reginput = regline + STRLEN(regline);
  29.                   fast_breakcheck();
  30.                   if (got_int || out_of_stack)
  31. ***************
  32. *** 4158,4164 ****
  33.       while (count < maxcount)
  34.       {
  35.           if (vim_isIDc(*scan) && (testval || !isdigit(*scan)))
  36. !         ++scan;
  37.           else if (*scan == NUL)
  38.           {
  39.           if (!WITH_NL(OP(p)) || reglnum == reg_maxline)
  40. --- 4161,4169 ----
  41.       while (count < maxcount)
  42.       {
  43.           if (vim_isIDc(*scan) && (testval || !isdigit(*scan)))
  44. !         {
  45. !         ADVANCE_P(scan);
  46. !         }
  47.           else if (*scan == NUL)
  48.           {
  49.           if (!WITH_NL(OP(p)) || reglnum == reg_maxline)
  50. *** ../vim60.152/src/version.c    Fri Jan 25 10:05:09 2002
  51. --- src/version.c    Mon Jan 28 13:59:07 2002
  52. ***************
  53. *** 608,609 ****
  54. --- 608,611 ----
  55.   {   /* Add new patch number below this line */
  56. + /**/
  57. +     153,
  58.   /**/
  59.  
  60. -- 
  61. hundred-and-one symptoms of being an internet addict:
  62. 87. Everyone you know asks why your phone line is always busy ...and
  63.     you tell them to send an e-mail.
  64.  
  65.  ///  Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net  \\\
  66. (((   Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim   )))
  67.  \\\  Help me helping AIDS orphans in Uganda - http://iccf-holland.org  ///
  68.