diff --git a/reactos/base/applications/fontview/fontview.c b/reactos/base/applications/fontview/fontview.c index 82fa44aff6a..72b183212ba 100644 --- a/reactos/base/applications/fontview/fontview.c +++ b/reactos/base/applications/fontview/fontview.c @@ -60,13 +60,10 @@ FormatString( static void ErrorMsgBox(HWND hParent, DWORD dwCaptionID, DWORD dwMessageId, ...) { - HMODULE hModule; HLOCAL hMemCaption = NULL; HLOCAL hMemText = NULL; va_list args; - hModule = GetModuleHandle(NULL); - va_start(args, dwMessageId); FormatString(FORMAT_MESSAGE_ALLOCATE_BUFFER, NULL, dwMessageId, 0, (LPWSTR)&hMemText, 0, &args); diff --git a/reactos/base/applications/kbswitch/kbswitch.c b/reactos/base/applications/kbswitch/kbswitch.c index 5c94c25f79a..03f196f7771 100644 --- a/reactos/base/applications/kbswitch/kbswitch.c +++ b/reactos/base/applications/kbswitch/kbswitch.c @@ -33,7 +33,6 @@ CreateTrayIcon(LPTSTR szLCID) HDC hdc, hdcsrc; HBITMAP hBitmap, hBmpNew, hBmpOld; RECT rect; - DWORD bkColor, bkText; HFONT hFontOld, hFont = NULL; ICONINFO IconInfo; HICON hIcon = NULL; @@ -63,8 +62,8 @@ CreateTrayIcon(LPTSTR szLCID) rect.bottom = 16; rect.top = 0; - bkColor = SetBkColor(hdc, GetSysColor(COLOR_HIGHLIGHT)); - bkText = SetTextColor(hdc, GetSysColor(COLOR_HIGHLIGHTTEXT)); + SetBkColor(hdc, GetSysColor(COLOR_HIGHLIGHT)); + SetTextColor(hdc, GetSysColor(COLOR_HIGHLIGHTTEXT)); ExtTextOut(hdc, rect.left, rect.top, ETO_OPAQUE, &rect, _T(""), 0, NULL); diff --git a/reactos/base/applications/magnify/magnifier.c b/reactos/base/applications/magnify/magnifier.c index 43816d6b5aa..4c2b4f623e9 100644 --- a/reactos/base/applications/magnify/magnifier.c +++ b/reactos/base/applications/magnify/magnifier.c @@ -295,7 +295,7 @@ void Draw(HDC aDc) // LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) { - int wmId, wmEvent; + int wmId; switch (message) { @@ -354,7 +354,6 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) break; case WM_COMMAND: wmId = LOWORD(wParam); - wmEvent = HIWORD(wParam); // Parse the menu selections: switch (wmId) { diff --git a/reactos/base/applications/mplay32/mplay32.c b/reactos/base/applications/mplay32/mplay32.c index 9b1b564908a..f4bd117a65f 100644 --- a/reactos/base/applications/mplay32/mplay32.c +++ b/reactos/base/applications/mplay32/mplay32.c @@ -407,7 +407,7 @@ PlayFile(HWND hwnd, LPTSTR lpFileName) MCI_PLAY_PARMS mciPlay; TCHAR szLocalFileName[MAX_PATH]; UINT FileType; - DWORD dwError; + MCIERROR mciError; if (lpFileName == NULL) { @@ -449,14 +449,14 @@ PlayFile(HWND hwnd, LPTSTR lpFileName) SetTimer(hwnd, IDT_PLAYTIMER, 100, (TIMERPROC) PlayTimerProc); - dwError = mciSendCommand(wDeviceId, MCI_SEEK, MCI_WAIT | MCI_SEEK_TO_START, 0); + mciSendCommand(wDeviceId, MCI_SEEK, MCI_WAIT | MCI_SEEK_TO_START, 0); mciPlay.dwCallback = (DWORD_PTR)hwnd; mciPlay.dwFrom = 0; mciPlay.dwTo = MaxFilePos; - dwError = mciSendCommand(wDeviceId, MCI_PLAY, MCI_NOTIFY | MCI_FROM | MCI_TO, (DWORD_PTR)&mciPlay); - if (dwError != 0) + mciError = mciSendCommand(wDeviceId, MCI_PLAY, MCI_NOTIFY | MCI_FROM | MCI_TO, (DWORD_PTR)&mciPlay); + if (mciError != 0) { MessageBox(hwnd, _T("Can't play!"), NULL, MB_OK); } @@ -641,12 +641,12 @@ MainWndProc(HWND hwnd, UINT Message, WPARAM wParam, LPARAM lParam) break; case IDM_ABOUT: - { + { HICON mplayIcon = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_MAIN)); ShellAbout(hwnd, szAppTitle, 0, mplayIcon); - DeleteObject(mplayIcon); + DeleteObject(mplayIcon); break; - } + } case IDM_EXIT: PostMessage(hwnd, WM_CLOSE, 0, 0); return 0; diff --git a/reactos/base/applications/mscutils/eventvwr/eventvwr.c b/reactos/base/applications/mscutils/eventvwr/eventvwr.c index dbe44a8b913..011c0ec5da6 100644 --- a/reactos/base/applications/mscutils/eventvwr/eventvwr.c +++ b/reactos/base/applications/mscutils/eventvwr/eventvwr.c @@ -506,7 +506,6 @@ QueryEventMessages(LPWSTR lpMachineName, DWORD dwRead, dwNeeded, dwThisRecord, dwTotalRecords = 0, dwCurrentRecord = 1, dwRecordsToRead = 0, dwFlags; LPWSTR lpSourceName; LPWSTR lpComputerName; - LPWSTR lpEventStr; LPWSTR lpData; BOOL bResult = TRUE; /* Read succeeded. */ @@ -609,9 +608,6 @@ QueryEventMessages(LPWSTR lpMachineName, // This ist the data section of the current event lpData = (LPWSTR)((LPBYTE)pevlr + pevlr->DataOffset); - // This is the text of the current event - lpEventStr = (LPWSTR)((LPBYTE)pevlr + pevlr->StringOffset); - // Compute the event type EventTimeToSystemTime(pevlr->TimeWritten, &time);