diff options
Diffstat (limited to 'Applications/SystemMonitor/ProcessStacksWidget.cpp')
-rw-r--r-- | Applications/SystemMonitor/ProcessStacksWidget.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Applications/SystemMonitor/ProcessStacksWidget.cpp b/Applications/SystemMonitor/ProcessStacksWidget.cpp index c54ffba358..73c94c4329 100644 --- a/Applications/SystemMonitor/ProcessStacksWidget.cpp +++ b/Applications/SystemMonitor/ProcessStacksWidget.cpp @@ -28,11 +28,11 @@ void ProcessStacksWidget::set_pid(pid_t pid) void ProcessStacksWidget::refresh() { - CFile file(String::format("/proc/%d/stack", m_pid)); - if (!file.open(CIODevice::ReadOnly)) { - m_stacks_editor->set_text(String::format("Unable to open %s", file.filename().characters())); + auto file = CFile::construct(String::format("/proc/%d/stack", m_pid)); + if (!file->open(CIODevice::ReadOnly)) { + m_stacks_editor->set_text(String::format("Unable to open %s", file->filename().characters())); return; } - m_stacks_editor->set_text(file.read_all()); + m_stacks_editor->set_text(file->read_all()); } |