fix log subdirectory handling