1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-06-01 10:08:10 +00:00

Kernel: Don't take LexicalPath as argument

LexicalPath is a big and heavy class that's really meant as a helper
for extracting parts of a path, not for storage or passing around.
Instead, pass paths around as strings and use LexicalPath locally
as needed.
This commit is contained in:
Andreas Kling 2020-12-15 11:17:01 +01:00
parent bcabbbda8b
commit ff8bf4db8d
4 changed files with 13 additions and 14 deletions

View file

@ -39,16 +39,14 @@ class Process;
class CoreDump {
public:
static OwnPtr<CoreDump> create(Process&, const LexicalPath& output_path);
static OwnPtr<CoreDump> create(Process&, const String& output_path);
~CoreDump();
void write();
// Has to be public for OwnPtr::make
CoreDump(Process&, NonnullRefPtr<FileDescription>&&);
private:
static RefPtr<FileDescription> create_target_file(const Process&, const LexicalPath& output_path);
CoreDump(Process&, NonnullRefPtr<FileDescription>&&);
static RefPtr<FileDescription> create_target_file(const Process&, const String& output_path);
void write_elf_header();
void write_program_headers(size_t notes_size);