From 62b03db531edda3e3db60e5b3f884e61477c75d8 Mon Sep 17 00:00:00 2001 From: baldurk Date: Fri, 12 Apr 2019 11:33:44 +0100 Subject: [PATCH] Fix mismatched wide/narrow string formatting --- renderdoc/os/win32/win32_callstack.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/renderdoc/os/win32/win32_callstack.cpp b/renderdoc/os/win32/win32_callstack.cpp index d0632a01a..cafafe47c 100644 --- a/renderdoc/os/win32/win32_callstack.cpp +++ b/renderdoc/os/win32/win32_callstack.cpp @@ -982,10 +982,10 @@ Win32CallstackResolver::Win32CallstackResolver(byte *moduleDB, size_t DBSize, m.name.find("symsrv.") != std::wstring::npos) continue; - wchar_t text[1024]; - wsprintf(text, L"Do you want to permanently ignore this file?\nPath: %s", m.name.c_str()); + std::string text = StringFormat::Fmt("Do you want to permanently ignore this file?\nPath: %s", + m.name.c_str()); - int ret = MessageBoxW(NULL, text, L"Ignore this pdb?", MB_YESNO); + int ret = MessageBoxA(NULL, text.c_str(), "Ignore this pdb?", MB_YESNO); if(ret == IDYES) pdbIgnores.push_back(m.name);