Fixed handling of spaces in file paths