server/vfs: do not append '/' to directory paths

Fix #2544
This commit is contained in:
Emery Hemingway 2017-10-23 21:59:14 -05:00 committed by Christian Helmuth
parent c1493b2ed2
commit 97c5e21ed6

View File

@ -427,7 +427,8 @@ class Vfs_server::Session_component : public File_system::Session_rpc_object,
_assert_valid_path(path_str);
Vfs_server::Path fullpath(_root->path());
fullpath.append(path_str);
if (path_str[1] != '\0')
fullpath.append(path_str);
path_str = fullpath.base();
if (!create && !_vfs.directory(path_str))