Fixes to safety via generalization