diff options
author | Karol Kosek <krkk@serenityos.org> | 2022-04-14 22:53:34 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2022-04-18 14:17:01 +0200 |
commit | 35cb5ea47ced471ae20d7dd87135ad3121e0c272 (patch) | |
tree | 619b0b12d92c678ea5fe6e19d6bfa58ca01026f6 /Userland/Utilities | |
parent | 00782d9a59030d1fbe507539b5510c0578784aaa (diff) | |
download | serenity-35cb5ea47ced471ae20d7dd87135ad3121e0c272.zip |
Utilities/profile: Call split_view() using StringView for command parts
This fixes the always appearing 'No such file' error when using the -c
flag, as the String was deconstructed right after running this line.
Diffstat (limited to 'Userland/Utilities')
-rw-r--r-- | Userland/Utilities/profile.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Utilities/profile.cpp b/Userland/Utilities/profile.cpp index d4e2800038..d213228e96 100644 --- a/Userland/Utilities/profile.cpp +++ b/Userland/Utilities/profile.cpp @@ -107,7 +107,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) return 0; } - auto cmd_parts = String(cmd_argument).split_view(' '); + auto cmd_parts = StringView(cmd_argument).split_view(' '); dbgln("Enabling profiling for PID {}", getpid()); TRY(Core::System::profiling_enable(getpid(), event_mask)); |