Fixed constructor for WindowsFilesystemNode. On Windows, trailing slashes can be added only to directory names.

svn-id: r33350
This commit is contained in:
Nicola Mettifogo 2008-07-28 02:56:17 +00:00
parent 06a45c49c7
commit b0e2cd5967

View File

@ -245,7 +245,7 @@ WindowsFilesystemNode::WindowsFilesystemNode(const String &p, const bool current
_isDirectory = ((fileAttribs & FILE_ATTRIBUTE_DIRECTORY) != 0);
_isValid = true;
// Add a trailing slash, if necessary.
if (_path.lastChar() != '\\') {
if (_isDirectory && _path.lastChar() != '\\') {
_path += '\\';
}
}