Initial commit
This commit is contained in:
commit
edfc5298e1
252 changed files with 93965 additions and 0 deletions
20
source/Platform/Win32/Win32Internal.cpp
Normal file
20
source/Platform/Win32/Win32Internal.cpp
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
|
||||
#include <string.h>
|
||||
#include "Win32Internal.h"
|
||||
|
||||
const char* Win32GetMessage(DWORD messageId) {
|
||||
|
||||
static char buf[1024] = { '\0' };
|
||||
|
||||
DWORD rc = FormatMessage(
|
||||
FORMAT_MESSAGE_IGNORE_INSERTS |
|
||||
FORMAT_MESSAGE_FROM_SYSTEM,
|
||||
NULL, messageId,
|
||||
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
|
||||
buf, 1024, NULL);
|
||||
|
||||
if (!rc) {
|
||||
strcpy_s(buf, "Unkown error!\n");
|
||||
}
|
||||
return buf;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue