Since the coconut throwing itself is counted (could be a bug) as an attack with zero hp drain against the player, the treeguard catches fire even without actually harming player in any way. So it keeps dancing till fire is out, then tries to throw coconut which simply makes him dance again. It will dance in fire till its death.
Most hilarious thing I have ever seen in Don't Starve, and I have been playing it since winter was implemented.
1. Play Shipwrecked 2. Wear an Obsidian Armor 3. Spawn a treeguard 4. Agro the treeguard, then stay half screen away. Do nothing. 5. Watch him dance in fire to death. Just enjoy. You don't have to do anything but watch the show.