"Adding function releaseClient and handling an error in recv function"