[ox/fs] Change substr function form
This commit is contained in:
parent
c0aa119155
commit
dd16577b50
@ -188,7 +188,7 @@ Error PassThroughFS::writeFileInode(uint64_t, const void*, uint64_t, FileType) n
|
|||||||
std::string_view PassThroughFS::stripSlash(StringView path) noexcept {
|
std::string_view PassThroughFS::stripSlash(StringView path) noexcept {
|
||||||
const auto pathLen = ox_strlen(path);
|
const auto pathLen = ox_strlen(path);
|
||||||
for (auto i = 0u; i < pathLen && path[0] == '/'; i++) {
|
for (auto i = 0u; i < pathLen && path[0] == '/'; i++) {
|
||||||
path = path.substr(1);
|
path = substr(path, 1);
|
||||||
}
|
}
|
||||||
return {path.data(), path.bytes()};
|
return {path.data(), path.bytes()};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user