diff options
author | Vitaly Tonkacheyev <Vitozz@users.noreply.github.com> | 2017-02-23 15:41:11 +0200 |
---|---|---|
committer | Itay Grudev <itay-grudev@users.noreply.github.com> | 2017-02-23 13:41:11 +0000 |
commit | eee5d9544b59e9b3ad6fd91446d0f682ccad95fb (patch) | |
tree | 9fbfaf3ca33af1ae44d5b24f9653766bff5d7398 | |
parent | Remove magic chars from code - use more readable code style (#28) (diff) | |
download | singleapplication-eee5d9544b59e9b3ad6fd91446d0f682ccad95fb.tar.xz |
Fixed compilation error: cannot convert wchar_t* to LPSTR {aka char*} (#29)
-rw-r--r-- | singleapplication.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/singleapplication.cpp b/singleapplication.cpp index ef7998a..31e3f0f 100644 --- a/singleapplication.cpp +++ b/singleapplication.cpp @@ -99,7 +99,7 @@ void SingleApplicationPrivate::genBlockServerName( int timeout ) wchar_t username [ UNLEN + 1 ]; // Specifies size of the buffer on input DWORD usernameLength = UNLEN + 1; - if( GetUserName( username, &usernameLength ) ) { + if( GetUserNameW( username, &usernameLength ) ) { appData.addData( QString::fromWCharArray(username).toUtf8() ); } else { appData.addData( QStandardPaths::standardLocations( QStandardPaths::HomeLocation ).join("").toUtf8() ); |