The Bodhisatta was once a woodpecker named Khadiravaniya, and be had a friend named Kandagalaka. One day Khadiravaniya took Kandagalaka with him into the acacia wood (khadiravana) and gave him insects from the acacia trees. As Kandagalaka ate them, pride rose in his heart and, feeling he could get food without his friend’s assistance, he told him so. In spite of the warning of Khadiravaniya, Kandagalaka pecked at an acacia trunk, broke his beak, and fell down dead.
The story was related in connection with Devadatta’s attempts to imitate the Buddha, these attempts ending in his own ruin. Kandagalaka is identified with Devadatta. J.ii.162‑4.