Merge "check thread group leader before killing process" into main