in reply to [XS] Callbacks to perl

The typedef for SV* includes a call to mortalise the SV, which is a postponed refcnt dec, so you need a corresponding refcnt inc. (Well, that's my guess.)