MCPcopy Create free account
hub / github.com/GPUOpen-Tools/compressonator / IsValidSubPath

Function IsValidSubPath

applications/_plugins/common/utilfuncs.cpp:306–322  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

304}
305
306BOOL IsValidSubPath(CString strPath)
307{
308 int nToken = max(strPath.ReverseFind('\\'), strPath.ReverseFind('/'));
309
310 if (nToken == strPath.GetLength())
311 return IsValidSubPath(strPath.Left(nToken - 1));
312
313 if (nToken > 0)
314 {
315 if (!IsValidName(strPath.Mid(nToken + 1)))
316 return FALSE;
317
318 return IsValidSubPath(strPath.Left(nToken));
319 }
320
321 return TRUE;
322}
323
324BOOL IsValidPath(const CString& strPath)
325{

Callers 1

IsValidPathFunction · 0.85

Calls 2

maxFunction · 0.85
IsValidNameFunction · 0.85

Tested by

no test coverage detected