1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-24 18:07:35 +00:00

Kernel: Use credentials object in LocalSocket constructor

This commit is contained in:
James Bellamy 2022-08-21 12:40:19 +01:00 committed by Andreas Kling
parent 386642ffcf
commit 2686640baf

View file

@ -73,8 +73,9 @@ LocalSocket::LocalSocket(int type, NonnullOwnPtr<DoubleBuffer> client_buffer, No
, m_for_server(move(server_buffer)) , m_for_server(move(server_buffer))
{ {
auto& current_process = Process::current(); auto& current_process = Process::current();
m_prebind_uid = current_process.euid(); auto current_process_credentials = current_process.credentials();
m_prebind_gid = current_process.egid(); m_prebind_uid = current_process_credentials->euid();
m_prebind_gid = current_process_credentials->egid();
m_prebind_mode = 0666; m_prebind_mode = 0666;
m_for_client->set_unblock_callback([this]() { m_for_client->set_unblock_callback([this]() {