Patch 8.2.4477
Problem:    Crash when using fuzzy completion.
Solution:   Temporary fix: put back regexp. (closes #9851)
Files:      src/cmdexpand.c


*** ../vim-8.2.4476/src/cmdexpand.c     2022-02-26 11:04:39.090453026 +0000
--- src/cmdexpand.c     2022-02-26 15:11:27.222716003 +0000
***************
*** 2370,2376 ****
      static int
  ExpandOther(
        char_u          *pat,
!       expand_T        *xp, 
        regmatch_T      *rmp,
        char_u          ***matches,
        int             *numMatches)
--- 2370,2376 ----
      static int
  ExpandOther(
        char_u          *pat,
!       expand_T        *xp,
        regmatch_T      *rmp,
        char_u          ***matches,
        int             *numMatches)
***************
*** 2496,2502 ****
      int               ret;
      int               flags;
      char_u    *tofree = NULL;
-     int               fuzzy = cmdline_fuzzy_complete(pat);
  
      flags = map_wildopts_to_ewflags(options);
  
--- 2496,2501 ----
***************
*** 2581,2595 ****
        pat = tofree;
      }
  
!     if (!fuzzy)
!     {
!       regmatch.regprog = vim_regcomp(pat, magic_isset() ? RE_MAGIC : 0);
!       if (regmatch.regprog == NULL)
!           return FAIL;
  
!       // set ignore-case according to p_ic, p_scs and pat
!       regmatch.rm_ic = ignorecase(pat);
!     }
  
      if (xp->xp_context == EXPAND_SETTINGS
            || xp->xp_context == EXPAND_BOOL_SETTINGS)
--- 2580,2591 ----
        pat = tofree;
      }
  
!     regmatch.regprog = vim_regcomp(pat, magic_isset() ? RE_MAGIC : 0);
!     if (regmatch.regprog == NULL)
!       return FAIL;
  
!     // set ignore-case according to p_ic, p_scs and pat
!     regmatch.rm_ic = ignorecase(pat);
  
      if (xp->xp_context == EXPAND_SETTINGS
            || xp->xp_context == EXPAND_BOOL_SETTINGS)
***************
*** 2603,2610 ****
      else
        ret = ExpandOther(pat, xp, &regmatch, matches, numMatches);
  
!     if (!fuzzy)
!       vim_regfree(regmatch.regprog);
      vim_free(tofree);
  
      return ret;
--- 2599,2605 ----
      else
        ret = ExpandOther(pat, xp, &regmatch, matches, numMatches);
  
!     vim_regfree(regmatch.regprog);
      vim_free(tofree);
  
      return ret;
*** ../vim-8.2.4476/src/version.c       2022-02-26 11:46:09.510212631 +0000
--- src/version.c       2022-02-26 15:51:38.764519836 +0000
***************
*** 756,757 ****
--- 756,759 ----
  {   /* Add new patch number below this line */
+ /**/
+     4477,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
111. You and your friends get together regularly on IRC, even though
     all of you live in the same street.

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///                                                                      \\\
\\\        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/20220226155330.20B9D1C114E%40moolenaar.net.

Raspunde prin e-mail lui