MCPcopy Create free account
hub / github.com/mhammond/pywin32 / NarrowString

Function NarrowString

win32/src/PythonService.cpp:590–597  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

588}
589
590static char *NarrowString(WCHAR *s)
591{
592 int cchNarrow = WideCharToMultiByte(CP_ACP, 0, s, -1, NULL, 0, NULL, NULL);
593 char *ret = (char *)malloc(cchNarrow);
594 if (ret)
595 WideCharToMultiByte(CP_ACP, 0, s, -1, ret, cchNarrow, NULL, NULL);
596 return ret;
597}
598
599// Couple of helpers for the service manager
600static void PyService_InitPython()

Callers 1

PyService_InitPythonFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected