Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 529a37d3 authored by Yurii Zubrytskyi's avatar Yurii Zubrytskyi
Browse files

[incfs] Fix bad path::join() path preparation

Bug: 151241369
Test: atest IncrementalServiceTest
Change-Id: I6e7655634de722c46e96e66b58c0c4c8e5098874
parent 9c5a02c2
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -44,7 +44,7 @@ bool PathLess::operator()(std::string_view l, std::string_view r) const {
                                        PathCharsLess());
}

static void preparePathComponent(std::string_view path, bool trimFront) {
static void preparePathComponent(std::string_view& path, bool trimFront) {
    if (trimFront) {
        while (!path.empty() && path.front() == '/') {
            path.remove_prefix(1);