mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 00:08:11 +00:00
Kernel: Remove unnecessary null check in Process::fork()
Found by PVS-Studio.
This commit is contained in:
parent
e8b3a539b4
commit
1a13145cb3
1 changed files with 0 additions and 2 deletions
|
@ -238,8 +238,6 @@ int Process::sys$gethostname(char* buffer, ssize_t size)
|
||||||
Process* Process::fork(RegisterDump& regs)
|
Process* Process::fork(RegisterDump& regs)
|
||||||
{
|
{
|
||||||
auto* child = new Process(String(m_name), m_uid, m_gid, m_pid, m_ring, m_cwd, m_executable, m_tty, this);
|
auto* child = new Process(String(m_name), m_uid, m_gid, m_pid, m_ring, m_cwd, m_executable, m_tty, this);
|
||||||
if (!child)
|
|
||||||
return nullptr;
|
|
||||||
|
|
||||||
#ifdef FORK_DEBUG
|
#ifdef FORK_DEBUG
|
||||||
dbgprintf("fork: child=%p\n", child);
|
dbgprintf("fork: child=%p\n", child);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue