summaryrefslogtreecommitdiff
path: root/src/palrt
diff options
context:
space:
mode:
authorJan Kotas <jkotas@microsoft.com>2019-01-02 04:46:32 -1000
committerGitHub <noreply@github.com>2019-01-02 04:46:32 -1000
commita082f4702540309e832c2ebdf86b15dc798b136b (patch)
treee79301329d1645563f39bba239bc03ac00e447b2 /src/palrt
parentd26e31a51d3a97ac925240c134d08418911c457d (diff)
downloadcoreclr-a082f4702540309e832c2ebdf86b15dc798b136b.tar.gz
coreclr-a082f4702540309e832c2ebdf86b15dc798b136b.tar.bz2
coreclr-a082f4702540309e832c2ebdf86b15dc798b136b.zip
Delete lstrlen from Unix PAL (#21745)
strlen/wcslen works just fine.
Diffstat (limited to 'src/palrt')
-rw-r--r--src/palrt/path.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/palrt/path.cpp b/src/palrt/path.cpp
index fc01183e33..3d6c7a6564 100644
--- a/src/palrt/path.cpp
+++ b/src/palrt/path.cpp
@@ -46,11 +46,11 @@ STDAPI_(LPWSTR) StrRChrW(LPCWSTR lpStart, LPCWSTR lpEnd, WCHAR wMatch)
LPCWSTR lpFound = NULL;
RIPMSG(lpStart && IS_VALID_STRING_PTRW(lpStart, -1), "StrRChrW: caller passed bad lpStart");
- RIPMSG(!lpEnd || lpEnd <= lpStart + lstrlenW(lpStart), "StrRChrW: caller passed bad lpEnd");
+ RIPMSG(!lpEnd || lpEnd <= lpStart + wcslen(lpStart), "StrRChrW: caller passed bad lpEnd");
// don't need to check for NULL lpStart
if (!lpEnd)
- lpEnd = lpStart + lstrlenW(lpStart);
+ lpEnd = lpStart + wcslen(lpStart);
for ( ; lpStart < lpEnd; lpStart++)
{
@@ -206,7 +206,7 @@ LPCWSTR GetPCEnd(LPCWSTR lpszStart)
}
if (!lpszEnd)
{
- lpszEnd = lpszStart + lstrlenW(lpszStart);
+ lpszEnd = lpszStart + wcslen(lpszStart);
}
return lpszEnd;
@@ -439,9 +439,9 @@ STDAPI_(LPWSTR) PathCombineW(LPWSTR lpszDest, LPCWSTR lpszDir, LPCWSTR lpszFile)
pszT = PathAddBackslashW(szTemp);
if (pszT)
{
- int iRemaining = (int)(ARRAYSIZE(szTemp) - (pszT - szTemp));
+ size_t iRemaining = ARRAYSIZE(szTemp) - (pszT - szTemp);
- if (lstrlenW(lpszFile) < iRemaining)
+ if (wcslen(lpszFile) < iRemaining)
{
StringCchCopyNW(pszT, iRemaining, lpszFile, iRemaining);
}
@@ -527,7 +527,7 @@ STDAPI_(LPWSTR) PathAddBackslashW(LPWSTR lpszPath)
if (lpszPath)
{
- int ichPath = lstrlenW(lpszPath);
+ size_t ichPath = wcslen(lpszPath);
LPWSTR lpszEnd = lpszPath + ichPath;
if (ichPath)