Will Ferrell nearly killed Zach Galifianakis by putting nuts in his breakfast burrito.

Galifianakis, who stars alongside Ferrell in The Campaign, suffers from a serious nut allergy and was treated by an on-set medic -- and luckily made a full recovery.

During an interview with Jon Stewart, Ferrell explained, "We had a lot of fun. There were a lot of pranks we pulled on each other... Zac has a nut allergy... and so I had the craft service guy put some walnuts in his breakfast burrito and his throat closed up, to the point where they were like, 'Someone call a doctor... no seriously, someone call a doctor!'"

"And the EMTs (Emergency Medical Technicians) came and they said, 'If had been five minutes later, he would have died.'"