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

Commit 874448f4 authored by Bart Van Assche's avatar Bart Van Assche Committed by Gerrit Code Review
Browse files

Merge "subcontext: Change a std::string argument into std::string_view"

parents f2d93ceb 462ea550
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -36,8 +36,10 @@ static constexpr const char kTestContext[] = "test-test-test";

class Subcontext {
  public:
    Subcontext(std::vector<std::string> path_prefixes, std::string context, bool host = false)
        : path_prefixes_(std::move(path_prefixes)), context_(std::move(context)), pid_(0) {
    Subcontext(std::vector<std::string> path_prefixes, std::string_view context, bool host = false)
        : path_prefixes_(std::move(path_prefixes)),
          context_(context.begin(), context.end()),
          pid_(0) {
        if (!host) {
            Fork();
        }