fixed bug in which names like bwa mem would create a file with a space