1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 04:47:34 +00:00

SharedBuffer: Amend commit 2d4d465206

I had the right cause of the SharedBuffer leak, but goofed the fix by
desynching the per-pid refcount and the global refcount.

Fix that, and add a generous sprinkle of asserts to make sure the two
stay in sync.

Fixes #341

(... for real this time)
This commit is contained in:
Robin Burchell 2019-07-19 23:14:56 +02:00 committed by Andreas Kling
parent 253e391bfc
commit 56217c7432
2 changed files with 29 additions and 1 deletions

View file

@ -32,6 +32,7 @@ public:
#endif
}
void sanity_check(const char* what);
bool is_shared_with(pid_t peer_pid);
void* ref_for_process_and_get_address(Process& process);
void share_with(pid_t peer_pid);