main: increase upper limit of pid when checking pidfile

Jan Vaclav requested to merge jvaclav/NetworkManager:jv/no-pid-upper-bound into main


This commit removes the upper limit for the PID, letting NetworkManager recognize a PID from the pidfile higher than 2^16.


The PID limit can be up to 2^22 (4194304) on 64-bit systems, while the current condition only allows PIDs up to 2^16, resulting in the pidfile being ignored and subsequently deleted if the currently running instance of NetworkManager has a higher PID. This is not a huge issue, since NetworkManager is launched pretty early most of the time and gets a low PID, but I think it should still be fixed regardless.


Please read before opening the merge request. In particular, check that:

  • the subject for all commits is concise and explicative
  • the message for all commits explains the reason for the change
  • the source is properly formatted
  • any relevant documentation is up to date
  • you have added unit tests if applicable
Edited by Jan Vaclav

Merge request reports