Stop memory leak from pending connections