Nagram/TMessagesProj/jni/libtgvoip2/os/windows/WindowsSpecific.cpp

9 lines
296 B
C++
Raw Normal View History

2020-03-30 12:00:09 +00:00
#include "WindowsSpecific.h"
using namespace tgvoip;
std::string WindowsSpecific::GetErrorMessage(DWORD code){
char buf[1024]={0};
FormatMessageA(FORMAT_MESSAGE_FROM_SYSTEM, NULL, code, MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US), buf, sizeof(buf), NULL);
return std::string(buf);
}