Shocking as it might seem, until the 1990s, homosexuality was an official bar to employment by the British Foreign Office. Charles Crawford, a former diplomat, recently made a Freedom of Information request in order to trace the slow evolution of the FCO's policy on this. He's written a really fascinating piece for the Independent about what he turned up. The main rationale for the ban was that homosexuality, or at least the supposedly more promiscuous lifestyle led by homosexuals, made them more vulnerable to blackmail. But of course, this was largely a self-created problem, with a self-defeating solution. It took until the end of the eighties for pennies to start dropping:
A turning point came in 1989, with the gradual realisation that the core security argument may in fact have created its own security problems, by exposing Foreign Office staff who were secretly gay to blackmail if a hostile intelligence agency discovered their "preferences".
At the same time, it was realised that homosexuals might actually have their advantages, as employees:
The official urged that the British look at other allies' laidback attitudes. "I was most impressed by the relaxed attitudes of the Spaniards," he said. "Because homosexuals have no domestic ties, the administration has a conscious policy of putting them in departments where long and unconscionable hours are the norm, eg. the Minister's Private Office. The system works admirably well."
Anyway, there's lots more great stuff, with more political context - do read the whole thing.
Particularly interesting in the light of the current struggle to repeal DADT.