If attacked by burrowing insects, many coniferous trees can secrete a scented, gummy resin that fills in the hole and then hardens to protect the tree from further damage. The scent of the resin also helps deter other insects from approaching the tree again.