MCPcopy Create free account
hub / github.com/FirebirdSQL/firebird / getCurrentModulePath

Function getCurrentModulePath

src/common/os/posix/os_utils.cpp:346–359  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

344}
345
346bool getCurrentModulePath(char* buffer, size_t bufferSize)
347{
348#ifdef HAVE_DLADDR
349 Dl_info path;
350
351 if (dladdr((void*) &getCurrentModulePath, &path))
352 {
353 strncpy(buffer, path.dli_fname, bufferSize);
354 return true;
355 }
356#endif
357
358 return false;
359}
360
361// setting flag is not absolutely required, therefore ignore errors here
362void setCloseOnExec(int fd)

Callers 2

printContentsMethod · 0.50
allCleanFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected