[NOTEPAD] LoadIcon() needs no DestroyIcon() (#5142)

CORE-18369
This commit is contained in:
Serge Gautherie 2023-03-20 22:19:30 +01:00 committed by GitHub
parent ed03768b1b
commit 3615e7c122
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -900,11 +900,9 @@ VOID DIALOG_HelpAboutNotepad(VOID)
TCHAR szNotepad[MAX_STRING_LEN];
TCHAR szNotepadAuthors[MAX_STRING_LEN];
HICON notepadIcon = LoadIcon(Globals.hInstance, MAKEINTRESOURCE(IDI_NPICON));
LoadString(Globals.hInstance, STRING_NOTEPAD, szNotepad, ARRAY_SIZE(szNotepad));
LoadString(Globals.hInstance, STRING_NOTEPAD_AUTHORS, szNotepadAuthors, ARRAY_SIZE(szNotepadAuthors));
ShellAbout(Globals.hMainWnd, szNotepad, szNotepadAuthors, notepadIcon);
DestroyIcon(notepadIcon);
ShellAbout(Globals.hMainWnd, szNotepad, szNotepadAuthors,
LoadIcon(Globals.hInstance, MAKEINTRESOURCE(IDI_NPICON)));
}