avoid bad directory names