fix 2010-psi-fix-memory-leaks.diff after recent changes in upstream