About 3,500 inmates and 3,000 correctional officers suffered through the summer in stifling prisons where temperatures reached 9…