Skip to content

Commit

Permalink
PID cache is never cleared where fork is not used
Browse files Browse the repository at this point in the history
  • Loading branch information
nobu committed Apr 4, 2023
1 parent 05b7bbe commit 1d529f3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions process.c
Original file line number Diff line number Diff line change
Expand Up @@ -506,11 +506,13 @@ get_pid(void)
return PIDT2NUM(cached_pid);
}

#if defined HAVE_WORKING_FORK || defined HAVE_DAEMON
static void
clear_pid_cache(void)
{
cached_pid = 0;
}
#endif

/*
* call-seq:
Expand Down

0 comments on commit 1d529f3

Please sign in to comment.