summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwillmcgugan@gmail.com <willmcgugan@gmail.com@67cdc799-7952-0410-af00-57a81ceafa0f>2013-07-06 15:51:40 +0000
committerwillmcgugan@gmail.com <willmcgugan@gmail.com@67cdc799-7952-0410-af00-57a81ceafa0f>2013-07-06 15:51:40 +0000
commit9cb63fd34ea6e10316128ce0205d04c91912b715 (patch)
treeb1faa65d85bae356c09e8cf8bece778679ff9dc9
parentf554f9bfe2620effd79aad283aae682764c7d5f4 (diff)
downloadpyfilesystem-9cb63fd34ea6e10316128ce0205d04c91912b715.tar.gz
Fixed issue in memoryfs.makedir where a path containing a forward slash at the end would create a directory with an empty filename
git-svn-id: http://pyfilesystem.googlecode.com/svn/trunk@860 67cdc799-7952-0410-af00-57a81ceafa0f
-rw-r--r--fs/memoryfs.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/memoryfs.py b/fs/memoryfs.py
index 5fee808..d48cf9f 100644
--- a/fs/memoryfs.py
+++ b/fs/memoryfs.py
@@ -354,7 +354,7 @@ class MemoryFS(FS):
if allow_recreate:
return
raise DestinationExistsError(dirname)
- dirpath, dirname = pathsplit(dirname)
+ dirpath, dirname = pathsplit(dirname.rstrip('/'))
if recursive:
parent_dir = self._get_dir_entry(dirpath)