[DO NOT MERGE] Fix #10404 vt ptys not released