1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 22:48:11 +00:00

Kernel: Make PerformanceEventBuffer::to_json() return a KResult

There's a ton of things inside to_json() that could go wrong but we
don't know about it yet. One step at a time.
This commit is contained in:
Andreas Kling 2021-09-07 18:21:37 +02:00
parent 6f992d784f
commit 905065f8c8
5 changed files with 8 additions and 12 deletions

View file

@ -116,7 +116,7 @@ public:
return const_cast<PerformanceEventBuffer&>(*this).at(index);
}
bool to_json(KBufferBuilder&) const;
KResult to_json(KBufferBuilder&) const;
void add_process(const Process&, ProcessEventType event_type);
@ -126,7 +126,7 @@ private:
explicit PerformanceEventBuffer(NonnullOwnPtr<KBuffer>);
template<typename Serializer>
bool to_json_impl(Serializer&) const;
KResult to_json_impl(Serializer&) const;
PerformanceEvent& at(size_t index);