2
1
mirror of https://github.com/qpdf/qpdf.git synced 2024-06-05 03:40:53 +00:00

Include header for wcslen (fixes #405)

This commit is contained in:
Jay Berkenbilt 2020-02-29 08:43:05 -05:00
parent 154b65f2e9
commit bb6768b8f0

View File

@ -24,6 +24,7 @@
#include <string.h>
#include <fcntl.h>
#include <memory>
#include <cwchar>
#ifdef _WIN32
#include <windows.h>
#include <direct.h>
@ -2375,7 +2376,7 @@ QUtil::call_main_from_wmain(int argc, wchar_t* argv[], std::function<int(int, ch
for (int i = 0; i < argc; ++i)
{
std::string utf16;
for (size_t j = 0; j < wcslen(argv[i]); ++j)
for (size_t j = 0; j < std::wcslen(argv[i]); ++j)
{
unsigned short codepoint = static_cast<unsigned short>(argv[i][j]);
utf16.append(1, static_cast<char>(