fixed segv in TPI with PME, fixes #927