![](https://www.popsci.com/wp-content/uploads/2019/03/18/HSRZF7YMFSOH2U76PLC7NPDO6Y.jpg?quality=85&w=800)
![](https://www.popsci.com/wp-content/uploads/2019/03/18/HSRZF7YMFSOH2U76PLC7NPDO6Y.jpg?quality=85&w=800)
Among the promiscuous common fruit fly, sexually-transmitted infections run rampant. Female fruit flies, however, have a special kind of defense to lower the potential cost of getting down and dirty with another fly, according to a new study from the University of Bath in the UK. When they get in the mood, female flies can ramp up their immune defenses against fungal STIs, in what’s called immune anticipation.
According to the study, female fruit flies regulate certain immune and stress response genes when they hear the courtship song of a male. This helps them fight off sexually-transmitted infection from the fungus Metarhizium robertsii. One of these genes, Turandot M (TotM), specifically protected the flies against STIs. When the flies were exposed to a topical infection of the same fungus, the expression of TotM didn’t help at all.
The researchers suggest that this immune anticipation “is likely to be far more common than currently appreciated” in insects, as they write in Proceedings of the Royal Society B. “[T]he courtship-induced, pre-emptive upregulation of TotM might be representative of a general pattern of immune anticipation in insects, underlining the intimate link between brain, behaviour and immunity.”