Fixes some file permissions problems