Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Version 3.7

1. Use the fnameescape() function (if available) to escape special characters in file names.
  • Loading branch information...
commit 1a09bb223deab45d57b961b74e464b617f42740f 1 parent 11e10a6
@yegappan yegappan authored committed
Showing with 7 additions and 3 deletions.
  1. +7 −3 plugin/mru.vim
View
10 plugin/mru.vim
@@ -1,9 +1,9 @@
" File: mru.vim
" Author: Yegappan Lakshmanan (yegappan AT yahoo DOT com)
-" Version: 3.6
+" Version: 3.7
" Last Modified: December 22, 2013
" Copyright: Copyright (C) 2003-2013 Yegappan Lakshmanan
-" Permission is hereby granted to use and distribute this code,
+" License: Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright
" notice is copied with it. Like anything else that's free,
" mru.vim is provided *as is* and comes with no warranty of any
@@ -423,7 +423,11 @@ endfunction
" that should be escaped (for security reasons)
let s:esc_filename_chars = ' *?[{`$%#"|!<>();&' . "'\t\n"
function! s:MRU_escape_filename(fname)
- return escape(a:fname, s:esc_filename_chars)
+ if exists("*fnameescape")
+ return fnameescape(a:fname)
+ else
+ return escape(a:fname, s:esc_filename_chars)
+ endif
endfunction
" MRU_Edit_File {{{1
Please sign in to comment.
Something went wrong with that request. Please try again.