Some fixes to dirlist error path.