Merge pull request #593 from orbitcowboy/master

Assign LPVOID pointer with NULL before it's being used
This commit is contained in:
Sebastian Pipping 2022-03-30 15:02:15 +02:00 committed by GitHub
commit f1b05559cc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -107,7 +107,7 @@ filemap(const TCHAR *name,
static void
win32perror(const TCHAR *s) {
LPVOID buf;
LPVOID buf = NULL;
if (FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM,
NULL, GetLastError(),
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPTSTR)&buf, 0,