Fix bug : close server listening on port