Clean up unused resources.