Khagama

A brahmin who once cursed another brahmin Sahasrapat and turned him into a snake. They were friends, and once, during an agnihotra yajna, Sahasrapat scared Khagama using a snake made from grass. Khagama cursed him then and Sahasrapat asked for mercy. He was told that he would be released the day he saw Pramati’s son Ruru. From then on, Sahasrapat traveled many lands in the snake form. Once, Ruru’s wife Pramadwara died of snakebite and as per a divine messenger’s advice, Ruru gave half his lifespan to her.

But Ruru continued to hate snakes and began killing all the ones he laid eyes on. He saw Sahasrapat once and began to kill him, when Sahasrapat told him his story. Immediately he regained his original form as per Mahabharata Adiparva Chapter 11.