Woman prison officer quits over sex with criminal