bug fix when the filename have any whitespace