MCPcopy Create free account
hub / github.com/Tripwire/tripwire-open-source / tss_wcstombs

Function tss_wcstombs

src/core/codeconvert.cpp:1223–1240  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1221}
1222
1223int tss_wcstombs(ntmbs_t pbz, const_ntwcs_t pwz, size_t nCount)
1224{
1225 cDebug d("tss_wcstombs");
1226
1227 size_t nConv;
1228 size_t N;
1229 for (nConv = 0, N = 0; *pwz; ++pwz, pbz += N, ++nConv)
1230 {
1231 N = tss_wctomb(pbz, *pwz);
1232 if (N == (size_t)-1)
1233 {
1234 *pbz = cConvertUtil::ConvertNonChar((dbchar_t)*pwz);
1235 N = 1;
1236 }
1237 }
1238
1239 return (int)nConv;
1240}
1241
1242
1243int tss_mbstowcs(ntwcs_t pwz, const_ntmbs_t pbz, size_t nBytes)

Callers 1

ConvertMethod · 0.85

Calls 1

tss_wctombFunction · 0.85

Tested by

no test coverage detected