1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 10:38:11 +00:00

Use new format functions in remaining DevTools. (#3755)

* AK: Add formatter for JsonValue.

* Inspector: Use new format functions.

* Profiler: Use new format functions.

* UserspaceEmulator: Use new format functions.
This commit is contained in:
Paul Scharnofske 2020-10-13 18:34:27 +02:00 committed by GitHub
parent 626bb1be9c
commit d94f674bbb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 45 additions and 37 deletions

View file

@ -74,7 +74,7 @@ int main(int argc, char** argv)
auto profile = Profile::load_from_perfcore_file(path);
if (!profile) {
fprintf(stderr, "Unable to load profile '%s'\n", path);
warnln("Unable to load profile '{}'", path);
return 1;
}
@ -170,7 +170,7 @@ bool generate_profile(pid_t pid)
if (profiling_enable(pid) < 0) {
int saved_errno = errno;
GUI::MessageBox::show(nullptr, String::format("Unable to profile PID %d: %s", pid, strerror(saved_errno)), "Profiler", GUI::MessageBox::Type::Error);
GUI::MessageBox::show(nullptr, String::formatted("Unable to profile PID {}: {}", pid, strerror(saved_errno)), "Profiler", GUI::MessageBox::Type::Error);
return false;
}