diff --git a/src/winextras.cpp b/src/winextras.cpp index 0960aa084..7f7b4bf62 100644 --- a/src/winextras.cpp +++ b/src/winextras.cpp @@ -270,8 +270,6 @@ QString WinExtras::getForegroundWindowExePath() if (windowProcess != NULL) { WCHAR filename[MAX_PATH]; - TCHAR filename_xp[MAX_PATH]; - // qDebug() << QString::number(sizeof(filename)/sizeof(TCHAR)); if (pQueryFullProcessImageNameW) { // Windows Vista and later @@ -283,12 +281,8 @@ QString WinExtras::getForegroundWindowExePath() exePath = QString::fromWCharArray(filename); } else { - // Windows XP - memset(filename_xp, 0, sizeof(filename_xp)); - GetModuleFileNameEx(windowProcess, NULL, filename_xp, MAX_PATH * sizeof(TCHAR)); - exePath = QString(filename_xp); + qWarning() << "Windows XP is not supported"; } - CloseHandle(windowProcess); }