Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@philfry
Copy link

@philfry philfry commented Mar 14, 2019

Hi,
I'm also afflicted with #52. The problem only occurs with system incronjobs, while user incrontabs are not affected.
In UserTable::OnEvent(…) these type of incronjobs are handled differently. Incrond fork()s and handles the logic in the child process. User incrontabs are invoked by jumping to UserTable::RunAsUser(…) which runs the specified command by execlp()ing, replacing the child process. System incrontabs' commands are run using system() which is basically another fork() and an execl() – leading to another child process and keeping the first child alive.
By replacing system() with execl() the first child should be replaced by the desired command and no additional incrond-processes should show up.
Please correct me if I'm wrong.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant