MCPcopy Create free account
hub / github.com/apache/trafficserver / _basename

Function _basename

example/plugins/c-api/thread_pool/psi.cc:430–440  ·  view source on GitHub ↗

TODO: Use libc basename function ------------------------------------------------------------------------- strip_path Utility func to strip path from a filename (= _basename cmd on unix) Input: filename Output : None Return Value: Filename with path stripped -------------------------------------------------------------------------*/

Source from the content-addressed store, hash-verified

428 Filename with path stripped
429 -------------------------------------------------------------------------*/
430static const char *
431_basename(const char *filename)
432{
433 const char *cptr;
434 const char *ptr = filename;
435
436 while ((cptr = strchr(ptr, '/')) != nullptr) {
437 ptr = cptr + 1;
438 }
439 return ptr;
440}
441
442/*-------------------------------------------------------------------------
443 psi_include

Callers 1

psi_includeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected