diff options
author | D G Turner | 2017-01-12 05:44:50 +0000 |
---|---|---|
committer | D G Turner | 2017-01-12 05:44:50 +0000 |
commit | 4dc175a4c2109ae17f524bde3b574799fcd20a56 (patch) | |
tree | 36926317392378e3d6d7ef43ea6aa60b1087680e /backends/fs/windows | |
parent | 16439b346f4b0a6e008e61d65af34348d6ce9420 (diff) | |
download | scummvm-rg350-4dc175a4c2109ae17f524bde3b574799fcd20a56.tar.gz scummvm-rg350-4dc175a4c2109ae17f524bde3b574799fcd20a56.tar.bz2 scummvm-rg350-4dc175a4c2109ae17f524bde3b574799fcd20a56.zip |
WIN32: Fix Variable Shadowing Compiler Warnings.
These are emitted when using the MinGW compiler.
Diffstat (limited to 'backends/fs/windows')
-rw-r--r-- | backends/fs/windows/windows-fs.cpp | 10 | ||||
-rw-r--r-- | backends/fs/windows/windows-fs.h | 2 |
2 files changed, 6 insertions, 6 deletions
diff --git a/backends/fs/windows/windows-fs.cpp b/backends/fs/windows/windows-fs.cpp index b43686f911..caf0e31360 100644 --- a/backends/fs/windows/windows-fs.cpp +++ b/backends/fs/windows/windows-fs.cpp @@ -244,10 +244,10 @@ Common::WriteStream *WindowsFilesystemNode::createWriteStream() { return StdioStream::makeFromPath(getPath(), true); } -bool WindowsFilesystemNode::create(bool isDirectory) { +bool WindowsFilesystemNode::create(bool isDirectoryFlag) { bool success; - if (isDirectory) { + if (isDirectoryFlag) { success = CreateDirectory(toUnicode(_path.c_str()), NULL) != 0; } else { success = CreateFile(toUnicode(_path.c_str()), GENERIC_READ|GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL) != INVALID_HANDLE_VALUE; @@ -264,12 +264,12 @@ bool WindowsFilesystemNode::create(bool isDirectory) { _path += '\\'; } - if (_isDirectory != isDirectory) warning("failed to create %s: got %s", isDirectory ? "directory" : "file", _isDirectory ? "directory" : "file"); - return _isDirectory == isDirectory; + if (_isDirectory != isDirectoryFlag) warning("failed to create %s: got %s", isDirectoryFlag ? "directory" : "file", _isDirectory ? "directory" : "file"); + return _isDirectory == isDirectoryFlag; } warning("WindowsFilesystemNode: Create%s() was a success, but GetFileAttributes() indicates there is no such %s", - isDirectory ? "Directory" : "File", isDirectory ? "directory" : "file"); + isDirectoryFlag ? "Directory" : "File", isDirectoryFlag ? "directory" : "file"); return false; } diff --git a/backends/fs/windows/windows-fs.h b/backends/fs/windows/windows-fs.h index 7c9f2c1e1a..3758877f05 100644 --- a/backends/fs/windows/windows-fs.h +++ b/backends/fs/windows/windows-fs.h @@ -88,7 +88,7 @@ public: virtual Common::SeekableReadStream *createReadStream(); virtual Common::WriteStream *createWriteStream(); - virtual bool create(bool isDirectory); + virtual bool create(bool isDirectoryFlag); private: /** |