Close network connection to avoid duplicate session