add the conn close check