Handling null/empty root directory.