mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-22 09:19:03 +00:00
Utilities: Use File.error_string() instead of perror(3) in cpp-*
This commit is contained in:
committed by
Andreas Kling
parent
d51072629d
commit
60a4da8e20
@@ -21,7 +21,7 @@ int main(int argc, char** argv)
|
||||
path = "Source/little/main.cpp";
|
||||
auto file = Core::File::construct(path);
|
||||
if (!file->open(Core::OpenMode::ReadOnly)) {
|
||||
perror("open");
|
||||
warnln("Failed to open {}: {}", path, file->error_string());
|
||||
exit(1);
|
||||
}
|
||||
auto content = file->read_all();
|
||||
|
||||
Reference in New Issue
Block a user