catch exceptions from rmtree