Revert "[MacOSX] Use getpid() instead of getppid() because execve() inherits the same pid"

This reverts commit 4c807804dce586055a0f3b5df333dc5a5a0193b8.