mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 20:07:35 +00:00
Kernel: Stop using *LockRefPtr for Process pointers
The only persistent one of these was Thread::m_process and that never changes after initialization. Make it const to enforce this and switch everything over to RefPtr & NonnullRefPtr.
This commit is contained in:
parent
19084ef743
commit
65438d8a85
11 changed files with 42 additions and 42 deletions
|
@ -288,7 +288,7 @@ static ErrorOr<void> build_from_cached_data(KBufferBuilder& builder, ProcFSInode
|
|||
return {};
|
||||
}
|
||||
|
||||
ErrorOr<void> ProcFSInode::try_fetch_process_property_data(NonnullLockRefPtr<Process> process, KBufferBuilder& builder) const
|
||||
ErrorOr<void> ProcFSInode::try_fetch_process_property_data(NonnullRefPtr<Process> process, KBufferBuilder& builder) const
|
||||
{
|
||||
VERIFY(m_type == Type::ProcessProperty);
|
||||
if (m_subdirectory == process_fd_subdirectory_root_entry.subdirectory) {
|
||||
|
|
|
@ -69,7 +69,7 @@ private:
|
|||
virtual ErrorOr<NonnullRefPtr<Inode>> lookup(StringView name) override final;
|
||||
|
||||
ErrorOr<void> refresh_process_property_data(OpenFileDescription& description);
|
||||
ErrorOr<void> try_fetch_process_property_data(NonnullLockRefPtr<Process>, KBufferBuilder& builder) const;
|
||||
ErrorOr<void> try_fetch_process_property_data(NonnullRefPtr<Process>, KBufferBuilder& builder) const;
|
||||
|
||||
Type m_type;
|
||||
Optional<ProcessID> const m_associated_pid {};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue