JazzCore / ctrlp-cmatcher

CtrlP C matching extension
BSD 2-Clause "Simplified" License
207 stars 22 forks source link

Causes Vim to segfault #15

Closed garrettr closed 10 years ago

garrettr commented 10 years ago

Just installed ctrlp-cmatcher in Vim according to instructions in README. When I hit ctrlp, the menu pops up, says "Mixing..." for a second, and then gives me the prompt. As soon as I type any letter in the prompt, vim crashes and outputs:

Vim: Caught deadly signal SEGV
Segmentation fault

Relevant configuration in .vimrc:

" Ctrl-P
let g:ctrlp_map = '<c-p>'
let g:ctrlp_cmd = 'CtrlPMixed'
let g:ctrlp_clear_cache_on_exit = 0
let g:ctrlp_max_files = 0 " no limit
let g:ctrlp_match_func = {'match' : 'matcher#cmatch' }
JazzCore commented 10 years ago

Can you give some more details? At least your OS and gdb backtrace on crash.

JazzCore commented 10 years ago

Closing since no details were given.

Yggdroot commented 10 years ago

uname -a Linux 2.6.18-371.el5 #1 SMP Tue Oct 1 08:35:08 EDT 2013 x86_64 x86_64 x86_64 GNU/Linux

Program received signal SIGSEGV, Segmentation fault.                                                                                                     
0x00002aaaaee2c3fd in recursive_match (m=0x7ffffffebe30, haystack_idx=0, needle_idx=0, last_idx=0, score=0) at match.c:56
56      double memoized = m->memo[needle_idx * m->needle_len + haystack_idx];
(gdb) bt
#0  0x00002aaaaee2c3fd in recursive_match (m=0x7ffffffebe30, haystack_idx=0, needle_idx=0, last_idx=0, score=0) at match.c:56
#1  0x00002aaab03fa49e in find_match (str=0x2aaaaf9f0420, abbrev=0x2aaaaf9c35f8, mmode=0x2aaaaf9f0414 "full-line") at fuzzycomt.c:379
#2  0x00002aaab03fa56d in getLineMatches (paths=0x2aaaaf9c7d88, abbrev=0x2aaaaf9c35f8, matches=0x7ffffffebf20, mmode=0x2aaaaf9f0414 "full-line") at fuzzycomt.c:33
#3  0x00002aaab03fa6a4 in fuzzycomt_sorted_match_list (self=<value optimized out>, args=<value optimized out>) at fuzzycomt.c:304
#4  0x0000000000654ff2 in PyEval_EvalFrameEx ()
#5  0x00000000006564ab in PyEval_EvalCodeEx ()
#6  0x0000000000656522 in PyEval_EvalCode ()
#7  0x0000000000678f05 in PyRun_StringFlags ()
#8  0x00000000005cac0b in ?? ()
#9  0x00000000005ca2ba in ?? ()
#10 0x00000000005cb113 in ex_python ()
#11 0x00000000004ac3f1 in ?? ()
#12 0x00000000004ad97f in do_cmdline ()
#13 0x0000000000483d71 in ?? ()
JazzCore commented 10 years ago

What distro (and version) are you using?

Yggdroot commented 10 years ago

the latest.

Yggdroot commented 10 years ago

I think this issue should be reopened.

JazzCore commented 10 years ago

I've meant what linux distro are you using? And steps to reproduce are the same as it was in OPs problem?

Yggdroot commented 10 years ago

I find the root cause of my Segmentation fault, it is because I have also installed Command-T, which also have recursive_match function. So the issue now becomes that conflict with Command-T.

JazzCore commented 10 years ago

Good that you found the issue, I'll look into this on weekend