FYI, if it hasn't been mentioned, LR and ACR will do this as well. In the Lens Correction section there are various evaluation buttons that will auto-correct, either for Verticals, Horizontals, Full Perspective and an "Auto" which evaluates all of it and attempts to correct it in a balanced way...