1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-25 12:55:07 +00:00

FileManager: Fix file creation error message

s/String::format/String::formatted/ - the error message was not being
formatted properly.
This commit is contained in:
Linus Groh 2020-10-09 23:22:37 +01:00 committed by Andreas Kling
parent 2d84c0c184
commit fcd263f17b

View file

@ -511,7 +511,7 @@ void DirectoryView::setup_actions()
int fd = creat(new_file_path.characters(), 0666);
if (fd < 0) {
auto saved_errno = errno;
GUI::MessageBox::show(window(), String::format("creat(\"{}\") failed: {}", new_file_path, strerror(saved_errno)), "Error", GUI::MessageBox::Type::Error);
GUI::MessageBox::show(window(), String::formatted("creat(\"{}\") failed: {}", new_file_path, strerror(saved_errno)), "Error", GUI::MessageBox::Type::Error);
return;
}
rc = close(fd);