From a6248101e2fea4e2cdb73fac7158ad1e549eff16 Mon Sep 17 00:00:00 2001 From: Linus Groh Date: Sun, 30 May 2021 19:25:04 +0100 Subject: SpaceAnalyzer: Replace fprintf(stderr) with warnln() --- Userland/Applications/SpaceAnalyzer/main.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Userland/Applications') diff --git a/Userland/Applications/SpaceAnalyzer/main.cpp b/Userland/Applications/SpaceAnalyzer/main.cpp index e58324d462..c56e0a12a1 100644 --- a/Userland/Applications/SpaceAnalyzer/main.cpp +++ b/Userland/Applications/SpaceAnalyzer/main.cpp @@ -75,13 +75,13 @@ struct MountInfo { static void fill_mounts(Vector& output) { // Output info about currently mounted filesystems. - auto df = Core::File::construct("/proc/df"); - if (!df->open(Core::OpenMode::ReadOnly)) { - fprintf(stderr, "Failed to open /proc/df: %s\n", df->error_string()); + auto file = Core::File::construct("/proc/df"); + if (!file->open(Core::OpenMode::ReadOnly)) { + warnln("Failed to open {}: {}", file->name(), file->error_string()); return; } - auto content = df->read_all(); + auto content = file->read_all(); auto json = JsonValue::from_string(content); VERIFY(json.has_value()); -- cgit v1.2.3