From nobody Thu May 2 10:10:56 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1505390118358718.7253868844325; Thu, 14 Sep 2017 04:55:18 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B9BBB4ACC7; Thu, 14 Sep 2017 11:55:16 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 180E858829; Thu, 14 Sep 2017 11:55:16 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 1262B3FA5A; Thu, 14 Sep 2017 11:55:15 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v8EBThd4025799 for ; Thu, 14 Sep 2017 07:29:43 -0400 Received: by smtp.corp.redhat.com (Postfix) id 95357756C3; Thu, 14 Sep 2017 11:29:43 +0000 (UTC) Received: from mx1.redhat.com (ext-mx07.extmail.prod.ext.phx2.redhat.com [10.5.110.31]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 8F02E60F9A for ; Thu, 14 Sep 2017 11:29:41 +0000 (UTC) Received: from honk.sigxcpu.org (honk.sigxcpu.org [24.134.29.49]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B17F3C04B924 for ; Thu, 14 Sep 2017 11:29:39 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by honk.sigxcpu.org (Postfix) with ESMTP id 5D539FB02 for ; Thu, 14 Sep 2017 13:29:38 +0200 (CEST) Received: from honk.sigxcpu.org ([127.0.0.1]) by localhost (honk.sigxcpu.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id IL53joCF2nen for ; Thu, 14 Sep 2017 13:29:36 +0200 (CEST) Received: by bogon.sigxcpu.org (Postfix, from userid 1000) id B0F9C400E9; Thu, 14 Sep 2017 13:29:34 +0200 (CEST) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com B9BBB4ACC7 Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=sigxcpu.org Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com B9BBB4ACC7 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com B17F3C04B924 Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=sigxcpu.org Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=agx@sigxcpu.org DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com B17F3C04B924 X-Virus-Scanned: Debian amavisd-new at honk.sigxcpu.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" From: =?UTF-8?q?Guido=20G=C3=BCnther?= To: libvir-list@redhat.com Date: Thu, 14 Sep 2017 13:29:32 +0200 Message-Id: In-Reply-To: References: In-Reply-To: References: X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Thu, 14 Sep 2017 11:29:40 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Thu, 14 Sep 2017 11:29:40 +0000 (UTC) for IP:'24.134.29.49' DOMAIN:'honk.sigxcpu.org' HELO:'honk.sigxcpu.org' FROM:'agx@sigxcpu.org' RCPT:'' X-RedHat-Spam-Score: -0.001 (RP_MATCHES_RCVD) 24.134.29.49 honk.sigxcpu.org 24.134.29.49 honk.sigxcpu.org X-Scanned-By: MIMEDefang 2.78 on 10.5.110.31 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH libvirt-glib 1/3] Add some missing docs 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 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Thu, 14 Sep 2017 11:55:17 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" --- libvirt-gobject/libvirt-gobject-connection.c | 15 ++++++++++++++- libvirt-gobject/libvirt-gobject-domain.c | 2 +- libvirt-gobject/libvirt-gobject-stream.c | 10 ++++++++++ 3 files changed, 25 insertions(+), 2 deletions(-) diff --git a/libvirt-gobject/libvirt-gobject-connection.c b/libvirt-gobject= /libvirt-gobject-connection.c index 3f17265..47a3f0c 100644 --- a/libvirt-gobject/libvirt-gobject-connection.c +++ b/libvirt-gobject/libvirt-gobject-connection.c @@ -487,6 +487,10 @@ static gboolean _gvir_connection_open(GVirConnection *= conn, * gvir_connection_open: * @conn: a #GVirConnection * @cancellable: (allow-none)(transfer none): cancellation object + * + * Open a connection + * + * Returns: TRUE on success, FALSE on error */ gboolean gvir_connection_open(GVirConnection *conn, GCancellable *cancellable, @@ -495,6 +499,15 @@ gboolean gvir_connection_open(GVirConnection *conn, return _gvir_connection_open(conn, FALSE, cancellable, err); } =20 +/** + * gvir_connection_open_read_only: + * @conn: a #GVirConnection + * @cancellable: (allow-none)(transfer none): cancellation object + * + * Open a connection read only + * + * Returns: TRUE on success, FALSE on error + */ gboolean gvir_connection_open_read_only(GVirConnection *conn, GCancellable *cancellable, GError **err) @@ -1340,7 +1353,7 @@ G_DEFINE_BOXED_TYPE(GVirConnectionHandle, gvir_connec= tion_handle, * @conn: a #GVirConnection * @flags: flags to use for the stream * - * Return value: (transfer full): a #GVirStream stream, or NULL.The return= ed + * Return value: (transfer full): a #GVirStream stream, or NULL. The retur= ned * object should be unreffed with g_object_unref() when no longer needed. */ GVirStream *gvir_connection_get_stream(GVirConnection *self, diff --git a/libvirt-gobject/libvirt-gobject-domain.c b/libvirt-gobject/lib= virt-gobject-domain.c index 7be936d..3bfc65f 100644 --- a/libvirt-gobject/libvirt-gobject-domain.c +++ b/libvirt-gobject/libvirt-gobject-domain.c @@ -1088,8 +1088,8 @@ end: /** * gvir_domain_open_console: * @dom: (transfer none): the domain - * @devname: (transfer none)(allow-none): the device name * @stream: (transfer none): stream to use as output + * @devname: (transfer none)(allow-none): the device name * @flags: extra flags, currently unused * * Open a text console for the domain @dom, connecting it to the diff --git a/libvirt-gobject/libvirt-gobject-stream.c b/libvirt-gobject/lib= virt-gobject-stream.c index a518a19..b6bf774 100644 --- a/libvirt-gobject/libvirt-gobject-stream.c +++ b/libvirt-gobject/libvirt-gobject-stream.c @@ -67,6 +67,16 @@ enum { }; =20 =20 +/** + * SECTION:gvir-stream + * @short_description: Streaming operations for domain input and output + * + * #GVirStream implements #GInputStream and #GOutputStream for reading fro= m and + * writing to a domain e.g. via a text based console on a emulated serial = port. + * + * It is usually created via #gvir_connection_get_stream. + */ + #define GVIR_STREAM_ERROR gvir_stream_error_quark() =20 static void gvir_stream_update_events(GVirStream *stream); --=20 2.14.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Thu May 2 10:10:56 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1505389275061893.6923129354562; Thu, 14 Sep 2017 04:41:15 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id BF1A4806AD; Thu, 14 Sep 2017 11:41:13 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 1DA956CDA7; Thu, 14 Sep 2017 11:41:13 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 4E757180610F; Thu, 14 Sep 2017 11:41:12 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v8EBasVn027492 for ; Thu, 14 Sep 2017 07:36:54 -0400 Received: by smtp.corp.redhat.com (Postfix) id 9015E18214; Thu, 14 Sep 2017 11:36:54 +0000 (UTC) Received: from mx1.redhat.com (ext-mx08.extmail.prod.ext.phx2.redhat.com [10.5.110.32]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 8A2585C66F for ; Thu, 14 Sep 2017 11:36:52 +0000 (UTC) Received: from honk.sigxcpu.org (honk.sigxcpu.org [24.134.29.49]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 94CBCC0587E3 for ; Thu, 14 Sep 2017 11:36:50 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by honk.sigxcpu.org (Postfix) with ESMTP id 29C50FB03 for ; Thu, 14 Sep 2017 13:29:39 +0200 (CEST) Received: from honk.sigxcpu.org ([127.0.0.1]) by localhost (honk.sigxcpu.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id nshJT6FAVxQZ for ; Thu, 14 Sep 2017 13:29:38 +0200 (CEST) Received: by bogon.sigxcpu.org (Postfix, from userid 1000) id B50FF40523; Thu, 14 Sep 2017 13:29:34 +0200 (CEST) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com BF1A4806AD Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=sigxcpu.org Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com BF1A4806AD DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 94CBCC0587E3 Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=sigxcpu.org Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=agx@sigxcpu.org DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 94CBCC0587E3 X-Virus-Scanned: Debian amavisd-new at honk.sigxcpu.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" From: =?UTF-8?q?Guido=20G=C3=BCnther?= To: libvir-list@redhat.com Date: Thu, 14 Sep 2017 13:29:33 +0200 Message-Id: <7bb26811efc95f44900386f23391e9a0e426fa66.1505388501.git.agx@sigxcpu.org> In-Reply-To: References: In-Reply-To: References: X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Thu, 14 Sep 2017 11:36:51 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Thu, 14 Sep 2017 11:36:51 +0000 (UTC) for IP:'24.134.29.49' DOMAIN:'honk.sigxcpu.org' HELO:'honk.sigxcpu.org' FROM:'agx@sigxcpu.org' RCPT:'' X-RedHat-Spam-Score: -0.001 (RP_MATCHES_RCVD) 24.134.29.49 honk.sigxcpu.org 24.134.29.49 honk.sigxcpu.org X-Scanned-By: MIMEDefang 2.78 on 10.5.110.32 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH libvirt-glib 2/3] streams: fix references 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 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Thu, 14 Sep 2017 11:41:14 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" --- libvirt-gobject/libvirt-gobject-stream.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libvirt-gobject/libvirt-gobject-stream.c b/libvirt-gobject/lib= virt-gobject-stream.c index b6bf774..296c00e 100644 --- a/libvirt-gobject/libvirt-gobject-stream.c +++ b/libvirt-gobject/libvirt-gobject-stream.c @@ -396,7 +396,7 @@ stream_sink(virStreamPtr st G_GNUC_UNUSED, * * Receive the entire data stream, sending the data to the * requested data sink. This is simply a convenient alternative - * to virStreamRecv, for apps that do blocking-I/o. + * to #gvir_vir_stream_receive, for apps that do blocking-I/o. * * Returns: the number of bytes consumed or -1 upon error */ @@ -512,7 +512,7 @@ stream_source(virStreamPtr st G_GNUC_UNUSED, * * Send the entire data stream, sending the data to the * requested data source. This is simply a convenient alternative - * to virStreamRecv, for apps that do blocking-I/o. + * to #gvir_stream_send, for apps that do blocking-I/o. * * Returns: the number of bytes consumed or -1 upon error */ --=20 2.14.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Thu May 2 10:10:56 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1505389606910588.596145927861; Thu, 14 Sep 2017 04:46:46 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id BEB6A6906B; Thu, 14 Sep 2017 11:46:44 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 590EA60F9A; Thu, 14 Sep 2017 11:46:44 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 1DAA03FC75; Thu, 14 Sep 2017 11:46:43 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v8EBTiFg025805 for ; Thu, 14 Sep 2017 07:29:44 -0400 Received: by smtp.corp.redhat.com (Postfix) id B20FF62944; Thu, 14 Sep 2017 11:29:44 +0000 (UTC) Received: from mx1.redhat.com (ext-mx10.extmail.prod.ext.phx2.redhat.com [10.5.110.39]) by smtp.corp.redhat.com (Postfix) with ESMTPS id ABD526267E for ; Thu, 14 Sep 2017 11:29:42 +0000 (UTC) Received: from honk.sigxcpu.org (honk.sigxcpu.org [24.134.29.49]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 4D6865D687 for ; Thu, 14 Sep 2017 11:29:41 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by honk.sigxcpu.org (Postfix) with ESMTP id EDCA1FB04 for ; Thu, 14 Sep 2017 13:29:39 +0200 (CEST) Received: from honk.sigxcpu.org ([127.0.0.1]) by localhost (honk.sigxcpu.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8_kEtKvL0W1h for ; Thu, 14 Sep 2017 13:29:37 +0200 (CEST) Received: by bogon.sigxcpu.org (Postfix, from userid 1000) id BEBC94069D; Thu, 14 Sep 2017 13:29:34 +0200 (CEST) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com BEB6A6906B Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=sigxcpu.org Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com BEB6A6906B DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 4D6865D687 Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=sigxcpu.org Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=agx@sigxcpu.org DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 4D6865D687 X-Virus-Scanned: Debian amavisd-new at honk.sigxcpu.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" From: =?UTF-8?q?Guido=20G=C3=BCnther?= To: libvir-list@redhat.com Date: Thu, 14 Sep 2017 13:29:34 +0200 Message-Id: <4886ac4818780da8d1393c8518ab9f829901f691.1505388501.git.agx@sigxcpu.org> In-Reply-To: References: In-Reply-To: References: X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Thu, 14 Sep 2017 11:29:41 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Thu, 14 Sep 2017 11:29:41 +0000 (UTC) for IP:'24.134.29.49' DOMAIN:'honk.sigxcpu.org' HELO:'honk.sigxcpu.org' FROM:'agx@sigxcpu.org' RCPT:'' X-RedHat-Spam-Score: -0.001 (RP_MATCHES_RCVD) 24.134.29.49 honk.sigxcpu.org 24.134.29.49 honk.sigxcpu.org X-Scanned-By: MIMEDefang 2.78 on 10.5.110.39 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH libvirt-glib 3/3] gvir_stream_send: make it obvious that we send bytes 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 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Thu, 14 Sep 2017 11:46:45 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Fix doc and use a proper variable name --- libvirt-gobject/libvirt-gobject-stream.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/libvirt-gobject/libvirt-gobject-stream.c b/libvirt-gobject/lib= virt-gobject-stream.c index 296c00e..93788b5 100644 --- a/libvirt-gobject/libvirt-gobject-stream.c +++ b/libvirt-gobject/libvirt-gobject-stream.c @@ -440,15 +440,15 @@ gvir_stream_receive_all(GVirStream *self, * @cancellable: (allow-none): a %GCancellable or %NULL * @error: #GError for error reporting, or %NULL to ignore. * - * Send data (up to @size bytes) from a stream. + * Send data (up to @size bytes) to a stream. * On error -1 is returned and @error is set accordingly. * - * gvir_stream_send() can return any number of bytes, up to - * @size. If more than @size bytes have been sendd, the additional - * data will be returned in future calls to gvir_stream_send(). + * gvir_stream_send() can send any number of bytes, up to + * @size. If less than @size bytes have been send, the additional + * data can be sent in future calls to gvir_stream_send(). * - * If there is no data available, a %G_IO_ERROR_WOULD_BLOCK error will be - * returned. + * If the receiving end would block, a %G_IO_ERROR_WOULD_BLOCK error + * will be returned. * * Returns: Number of bytes written. */ @@ -458,7 +458,7 @@ gssize gvir_stream_send(GVirStream *self, GCancellable *cancellable, GError **error) { - int got; + int sent; =20 g_return_val_if_fail(GVIR_IS_STREAM(self), -1); g_return_val_if_fail(buffer !=3D NULL, -1); @@ -468,17 +468,17 @@ gssize gvir_stream_send(GVirStream *self, if (g_cancellable_set_error_if_cancelled (cancellable, error)) return -1; =20 - got =3D virStreamSend(self->priv->handle, buffer, size); + sent =3D virStreamSend(self->priv->handle, buffer, size); =20 - if (got =3D=3D -2) { /* blocking */ + if (sent =3D=3D -2) { /* blocking */ g_set_error_literal(error, G_IO_ERROR, G_IO_ERROR_WOULD_BLOCK, _("virStreamSend call would block")); - } else if (got < 0) { + } else if (sent < 0) { g_set_error(error, G_IO_ERROR, G_IO_ERROR_INVALID_ARGUMENT, - _("Got virStreamRecv error in %s"), G_STRFUNC); + _("Sent virStreamRecv error in %s"), G_STRFUNC); } =20 - return got; + return sent; } =20 struct stream_source_helper { --=20 2.14.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list