clean up lofs resources in error conditions