modified mothed of send connection to a waiting process