summaryrefslogtreecommitdiff
path: root/src/shared/proparser/ioutils.cpp
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@nokia.com>2010-06-10 17:03:02 +0200
committerOswald Buddenhagen <oswald.buddenhagen@nokia.com>2010-06-10 17:05:44 +0200
commit24f07b7a72a0f07068a63b6b576cce51609dfc7f (patch)
treea961384526fe524ce80f3625adee986479195570 /src/shared/proparser/ioutils.cpp
parente80a4b962f096b006ca01761fad485f475813fd1 (diff)
downloadqt-creator-24f07b7a72a0f07068a63b6b576cce51609dfc7f.tar.gz
fix wildcard expansion, etc. under windows
raw strings would break things due to the missing null terminator. this did not affect unix, as there we convert to 8 bit anyway. Task-number: QTCREATORBUG-1364
Diffstat (limited to 'src/shared/proparser/ioutils.cpp')
-rw-r--r--src/shared/proparser/ioutils.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shared/proparser/ioutils.cpp b/src/shared/proparser/ioutils.cpp
index f43c29aa9a..5ed9ea5022 100644
--- a/src/shared/proparser/ioutils.cpp
+++ b/src/shared/proparser/ioutils.cpp
@@ -46,7 +46,7 @@ IoUtils::FileType IoUtils::fileType(const QString &fileName)
{
Q_ASSERT(fileName.isEmpty() || isAbsolutePath(fileName));
#ifdef Q_OS_WIN
- DWORD attr = GetFileAttributesW((WCHAR*)fileName.constData());
+ DWORD attr = GetFileAttributesW((WCHAR*)fileName.utf16());
if (attr == INVALID_FILE_ATTRIBUTES)
return FileNotFound;
return (attr & FILE_ATTRIBUTE_DIRECTORY) ? FileIsDir : FileIsRegular;