From f0368a1de607f3810ec57b29dff3d10ac3913b75 Mon Sep 17 00:00:00 2001 From: IdanArye Date: Wed, 11 Jun 2014 22:05:20 +0300 Subject: [PATCH] Use a pattern instead of fnamemodify for MDbg breakpoints --- autoload/vebugger/mdbg.vim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/autoload/vebugger/mdbg.vim b/autoload/vebugger/mdbg.vim index 6ac5659..fff7888 100644 --- a/autoload/vebugger/mdbg.vim +++ b/autoload/vebugger/mdbg.vim @@ -146,7 +146,8 @@ function! s:breakpointAdded(readResult,debugger) if !empty(a:readResult.mdbg.breakpointBound) let l:breakpointBound=a:readResult.mdbg.breakpointBound let l:lookFor=l:breakpointBound.fileNameTail.':'.l:breakpointBound.line - let l:matchingKeys=filter(keys(a:debugger.state.mdbg.breakpointNumbers),'fnamemodify(v:val,":t")==l:lookFor') + let l:lookForRegex='\V'.escape(l:lookFor,'\').'\$' + let l:matchingKeys=filter(keys(a:debugger.state.mdbg.breakpointNumbers),'v:val=~l:lookForRegex') for l:key in l:matchingKeys if empty(a:debugger.state.mdbg.breakpointNumbers[l:key]) let a:debugger.state.mdbg.breakpointNumbers[l:key]={'number':l:breakpointBound.breakpointNumber}