From patchwork Sun Apr 24 20:58:45 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cole Robinson X-Patchwork-Id: 66544 Delivered-To: patch@linaro.org Received: by 10.140.93.198 with SMTP id d64csp720998qge; Sun, 24 Apr 2016 14:01:47 -0700 (PDT) X-Received: by 10.194.246.3 with SMTP id xs3mr3895273wjc.66.1461531707532; Sun, 24 Apr 2016 14:01:47 -0700 (PDT) Return-Path: Received: from mx3-phx2.redhat.com (mx3-phx2.redhat.com. [209.132.183.24]) by mx.google.com with ESMTPS id eu6si20827998wjd.50.2016.04.24.14.01.46 (version=TLS1 cipher=AES128-SHA bits=128/128); Sun, 24 Apr 2016 14:01:47 -0700 (PDT) Received-SPF: pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.24 as permitted sender) client-ip=209.132.183.24; Authentication-Results: mx.google.com; spf=pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.24 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by mx3-phx2.redhat.com (8.13.8/8.13.8) with ESMTP id u3OKwtM4029009; Sun, 24 Apr 2016 16:58:56 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id u3OKwsuH031826 for ; Sun, 24 Apr 2016 16:58:54 -0400 Received: from colepc.redhat.com (ovpn-113-101.phx2.redhat.com [10.3.113.101]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u3OKwrw7010332; Sun, 24 Apr 2016 16:58:54 -0400 From: Cole Robinson To: libvirt-list@redhat.com Date: Sun, 24 Apr 2016 16:58:45 -0400 Message-Id: X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 1/2] rpc: protocol: Clarify VIR_NET_ERROR usage with streams X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com The described protocol semantics really only apply to server initiated stream messages. Document the semantics for client messages. --- AFAICT, the only time a server will receive VIR_NET_ERROR stream message from a client is via an explicit virStreamAbort call (which hits remote_driver.c:remoteStreamAbort) src/rpc/virnetprotocol.x | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) -- 2.7.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list diff --git a/src/rpc/virnetprotocol.x b/src/rpc/virnetprotocol.x index 327a334..9ce33b0 100644 --- a/src/rpc/virnetprotocol.x +++ b/src/rpc/virnetprotocol.x @@ -104,7 +104,9 @@ const VIR_NET_MESSAGE_NUM_FDS_MAX = 32; * - type == VIR_NET_STREAM * * VIR_NET_CONTINUE if more data is following * * VIR_NET_OK if stream is complete - * * VIR_NET_ERROR if stream had an error + * * VIR_NET_ERROR + * server message: stream had an error + * client message: client aborted the stream * * Payload varies according to type and status: * @@ -125,7 +127,8 @@ const VIR_NET_MESSAGE_NUM_FDS_MAX = 32; * * status == VIR_NET_CONTINUE * byte[] raw stream data * * status == VIR_NET_ERROR - * remote_error error information + * server message: remote_error error information + * client message: * * status == VIR_NET_OK * *