path fixes to account for spaces under Unix

Fixed to match, under Linux and Mac, the fix applied for paths with spaces in the Windows case.