Cleanup warnings and error