I would probably move your 'log persistence' check to here:
https://github.com/EQEmu/Server/blob...cket.cpp#L1628
.. you could even make the
database.LoadPetsInfo(this) call an else clause of the con check (PetLogPersistence == true)
I'm not 100% sure..but, that may clear up your client crashes too. (Looks like the profile packet was already sent to the client - with pet info - and you
were deleting the pet on the server afterwards.)
Mixing system methodologies can lead to issues down the road if you need to make changes, or if changes are made, to a code section.
The 'zone persistence' is probably ok (didn't look at the actual location) .. but, consider what you want to default behavior to be in case of a server crash, client ld, etc...
(Some) players will find a way to manipulate your best thought plans..even accidental actions can lead to exploitable discoveries.