This is, I believe, technically correct. It is also, I believe, really silly.
Imagine a pair of mated brown bears that live out in the woods. They're guarding some cubs, so they attack the hapless party of adventurers on sight. This is an el5 encounter, and the PCs get XP for defeating two CR3 creatures.
Now add a 6th-level NPC druid to the mix. She lives in the woods and doesn't adventure, and therefore can have double her level in HD of animal companions: these two brown bears are her companions. She can spend the battle doing things like casting entangle on the PCs, greater magic fangs on the bears, and then barkskin and shillelagh on herself and wade into combat all nastilike.
Now it's a el6 encounter, and the PCs get XP only for defeating a CR6 creature. Note that if the druid hadn't cast animal friendship on the bears -- if, for example, she'd trained them to guard her the hard way -- then the encounter would be el7-8, despite the fact that she wouldn't have nearly as good coordination with them as that granted her by the spell.
Can anyone tell me what the XP a party of 5th-level PCs would get for these two encounters? My guess is that, despite the significantly harder nature of the druid encounter, the PCs won't get significantly more XP for it.
Daniel