mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 17:57:35 +00:00
LibCore: Move Core::Stream::File::exists()
to Core::File
`Core::Stream::File` shouldn't hold any utility methods that are unrelated to constructing a `Core::Stream`, so let's just replace the existing `Core::File::exists` with the nicer looking implementation.
This commit is contained in:
parent
bd272e638c
commit
2fc2025f49
10 changed files with 14 additions and 18 deletions
|
@ -6,6 +6,7 @@
|
|||
|
||||
#include "ImageCodecPluginSerenity.h"
|
||||
#include <LibCore/EventLoop.h>
|
||||
#include <LibCore/File.h>
|
||||
#include <LibCore/LocalServer.h>
|
||||
#include <LibCore/Stream.h>
|
||||
#include <LibCore/System.h>
|
||||
|
@ -26,7 +27,7 @@ ErrorOr<int> serenity_main(Main::Arguments)
|
|||
TRY(Core::System::pledge("stdio recvfd sendfd accept unix rpath"));
|
||||
|
||||
// This must be first; we can't check if /tmp/webdriver exists once we've unveiled other paths.
|
||||
if (Core::Stream::File::exists("/tmp/webdriver"sv))
|
||||
if (Core::File::exists("/tmp/webdriver"sv))
|
||||
TRY(Core::System::unveil("/tmp/webdriver", "rw"));
|
||||
|
||||
TRY(Core::System::unveil("/sys/kernel/processes", "r"));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue