Fixup code formatting in EAP-LEAP, and use R*log functions
Fix places where old VP values were not freed