I'm going to reply, also without searching.
My understanding is that nicotine is a natural insect repellent which the tobacco plant has developed as resistance.
Nicotine is also present in tomatoes and other plants, but in much smaller concentrations.
Right, off to Google it now.