Fix process detection for Mac