I'm now using code from both post #9 and post #11 just to be safe. While I was discussing this with HoF he expressed some of the same concerns I had, however, so it's worth bringing up:
We don't really know if other side effects will exist. I can't immediately fathom any, but that doesn't mean they don't exist. What if a pet is deleted half way through a trade? Will it corrupt the trade section for one person, both people, everyone? And, is it possible to to keep the pet's profile open, release it to the pound, and because you still have your pet's page open as if you own it - delete it? Would that break the pound? I haven't fully considered these things so please do some testing.
It's hard to officially approve of deleting pets when we don't know what could happen.