client: fix SNI context memory leak