is_dir_empty() leaking fd's; notaz found it :)