Buckling roof plywood below asphalt shingles is a result of many things. Wood expands and contracts, so there may not have been adequate planned spacing between plywood boards. Check for proper attic ventilation. A buildup of water vapor is a problem.
Borate chemicals are highly toxic to wood boring insects, like termites and fungi but are safe for humans and animals. They come in powdery mixes and can be applied to existing wood. Make sure the one you buy is marked as a wood preservative.