Although that may seem like a dirty trick, females of the Photinus genus of fireflies play an even nastier trick. Fireflies attract a mate by flashing a signal that is specific to their species. However, the female Photinus flashes the signals of other species. The males will land, thinking they will mate with a female of their own species. They realize too late that they have become Photinus food.
Insects have to worry about more than being eaten.
They also have to make sure that their sperm, not another male's, fertilize the female's eggs. Most female insects store sperm in a storage pouch called the spermatheca, and the eggs are fertilized later. To make sure their sperm fertilize the eggs, many male damselflies have a structure to scoop out the previous male's sperm from the female's spermatheca. Male migratory locusts plug the spermatheca opening so other males cannot deposit their sperm. Some male butterflies even coat the female's genitalia with a substance that hardens, preventing her from mating with other males.