I'd move the code to define locale to just before when _make_mail is called.