MCPcopy Create free account
hub / github.com/bytedance/Fastbot_Android / EnsureDirExists

Function EnsureDirExists

native/thirdpart/flatbuffers/util.cpp:180–191  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

178}
179
180void EnsureDirExists(const std::string &filepath) {
181 auto parent = StripFileName(filepath);
182 if (parent.length()) EnsureDirExists(parent);
183 // clang-format off
184
185 #ifdef _WIN32
186 (void)_mkdir(filepath.c_str());
187 #else
188 mkdir(filepath.c_str(), S_IRWXU|S_IRGRP|S_IXGRP);
189 #endif
190 // clang-format on
191}
192
193std::string AbsolutePath(const std::string &filepath) {
194 // clang-format off

Callers 2

CompileMethod · 0.85
NamespaceDirMethod · 0.85

Calls 3

StripFileNameFunction · 0.85
lengthMethod · 0.80
c_strMethod · 0.45

Tested by

no test coverage detected