diff options
author | Seth Jackson <sethjackson@gmail.com> | 2015-12-11 20:12:13 -0500 |
---|---|---|
committer | Seth Jackson <sethjackson@gmail.com> | 2015-12-11 20:26:38 -0500 |
commit | 7f8365e3027880d1ddec7f02281b5922ab29ac0c (patch) | |
tree | e0f3ccd16ce8c393299c359a0721a180ab9eae3c /src | |
parent | 81960df9f55a1d378185e381fd81c2f21b56e085 (diff) | |
download | rneovim-7f8365e3027880d1ddec7f02281b5922ab29ac0c.tar.gz rneovim-7f8365e3027880d1ddec7f02281b5922ab29ac0c.tar.bz2 rneovim-7f8365e3027880d1ddec7f02281b5922ab29ac0c.zip |
Windows: Remove unnecessary codepath from modname.
File names starting with periods are perfectly acceptable on Windows
file systems. The only place where this is not acceptable is on
MS-DOS FAT file systems which only support 8.3 file names.
See here:
https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247%28v=vs.85%29.aspx
Since Neovim does not support MS-DOS or 8.3 file names (#605)
we can drop this codepath.
It was not compiling anyways since we do not define WIN3264.
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/fileio.c | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/src/nvim/fileio.c b/src/nvim/fileio.c index 5ac133a0c3..11673785fd 100644 --- a/src/nvim/fileio.c +++ b/src/nvim/fileio.c @@ -4331,8 +4331,6 @@ void shorten_fnames(int force) /// @return [allocated] - A new filename, made up from: /// * fname + ext, if fname not NULL. /// * current dir + ext, if fname is NULL. -/// On Windows, and if ext starts with ".", a "_" is -/// preprended to ext (for filename to be valid). /// Result is guaranteed to: /// * be ended by <ext>. /// * have a basename with at most BASENAMELEN chars: @@ -4386,15 +4384,6 @@ char *modname(const char *fname, const char *ext, bool prepend_dot) char *s; s = ptr + strlen(ptr); -#if defined(WIN3264) - // If there is no file name, and the extension starts with '.', put a - // '_' before the dot, because just ".ext" may be invalid if it's on a - // FAT partition, and on HPFS it doesn't matter. - else if ((fname == NULL || *fname == NUL) && *ext == '.') { - *s++ = '_'; - } -#endif - // Append the extension. // ext can start with '.' and cannot exceed 3 more characters. strcpy(s, ext); |