A cross between Accidental Innuendo and Unusual Euphemism. This trope occurs when "language drift" — natural changes in the common vocabulary — causes a word or phrase originally intended as wholly innocuous to be potentially taken as startling, confusing or just plain funny in a different time or place. Usually relates to sexual euphemisms, but can also involve other sensitive concepts. Political correctness sometimes comes into play.
Even very slight changes in usage can produce this effect; until recently, a man might speak of his attraction to a "young girl" and mean a twentysomething. Nowadays she'd be young, or a girl, but not both. And sometimes the expression still has an innocent meaning that is at least as valid as the naughty one, but now there are just too many people with their minds in the gutter.
Compare with Hilarious in Hindsight, of which this is arguably a Sub-Trope. See also Double Entendre or Intentionally Awkward Title for when this trope is invoked entirely intentionally, Separated by a Common Language for the spatial analogue, and Get Thee to a Nunnery for the reverse process.
Keep in mind that some of these words actually did have their modern meaning at the time they were used, but only within certain sections of the populace. The meaning of the word "gay" began to change as early as 1870 among the criminal classes of New York, where it originally meant "prostitute" (yes, before The Gay Nineties); around 1900 the meaning changed to "homosexual prostitute" and within five years of that to simply "homosexual". This means that in some cases the writers are using the words deliberately in order to get crap past the radar.
Some of these examples result from the euphemism treadmill, whereby terms are repeatedly replaced as the previous word falls into such a state of misuse that it cannot be recovered. The words "idiot", "moron", and "imbecile" started as clinical terms, referring to people with IQ's below 75, 50, and 25, respectively. As these terms fell into common use as insults, they were replaced by a kinder and gentler term: retarded. Nowadays, retarded is considered so virulent that some people want it classified as hate speech. The term used to describe people with life-changing diseases or injuries followed a similar path, from "crippled" to "disabled" to "handicapped" to "physically challenged"; when terms like "handi-capable" and "differently abled" were proposed, it came across as Political Correctness Gone Mad and people generally agreed to stop messing with it.
Words changed meaning less frequently before the advent of radio and television, and when they did change the transformation could be slow (as seen with "gay" above). It took over a hundred years for the primary meaning of the verb "want" to change from "lack" to "desire". Television sped things up: it took only a few weeks in the 70s for the meaning of "boob" to change from "dummy" to "breast" among the general public. Naturally, with the advent of the uncensored Internet words can change meaning almost overnight these days.