Clean up some debug errors and warnings.