From nobody Fri Apr 19 19:39:31 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1574681018; cv=none; d=zohomail.com; s=zohoarc; b=a6CEwpTO/f74zxc7+yZTZ9OMg7By7Xh1T1r5Z7ry6X63RcbfIKTOKClOGCE36fdxLYqu2aOASYGBRwfCX6R4isSTZshe9tFdEGzI4T83X2rJ3V6lxXtdwhBrmarOfLZZjUjOER7BXRMXeHTTps+6cKrZKR1dvPN06n1P8Rd6nLU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1574681018; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=01mfmHmc3pZQbbO1Ft9wsZqQ9+Pv983dQjJgkVggzz0=; b=gUoOn0XbOfFp6hZkqbLtqz8HseiT68NPRh5rUYmOhsgLp2+J0gb/iwiEVoPidVxoSbr9S98kJDzN3ooF7z9T9FeboFqnMwr8Bp2/I1q9fRc9h7/DaKSR60tv0AzISNeSZZyzMUcZY6wcOBfSmxe3Ail9A27iqLyQlevXkPBE0nU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1574681018229864.5750681773238; Mon, 25 Nov 2019 03:23:38 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-384-ffcHOtCGMQCSa4eqn-4I2w-1; Mon, 25 Nov 2019 06:23:35 -0500 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C49DFDBE6; Mon, 25 Nov 2019 11:23:30 +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 93464600C6; Mon, 25 Nov 2019 11:23:30 +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 488234BB65; Mon, 25 Nov 2019 11:23:29 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id xAPBNSDq012840 for ; Mon, 25 Nov 2019 06:23:28 -0500 Received: by smtp.corp.redhat.com (Postfix) id E6775206320A; Mon, 25 Nov 2019 11:23:27 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast01.extmail.prod.ext.rdu2.redhat.com [10.11.55.17]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E2A032063205 for ; Mon, 25 Nov 2019 11:23:25 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-1.mimecast.com [207.211.31.81]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id BE5268F71B6 for ; Mon, 25 Nov 2019 11:23:25 +0000 (UTC) Received: from mail-pl1-f194.google.com (mail-pl1-f194.google.com [209.85.214.194]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-325-jGZ7cZQIN465b_bxASfVrw-1; Mon, 25 Nov 2019 06:23:21 -0500 Received: by mail-pl1-f194.google.com with SMTP id az9so6365493plb.11; Mon, 25 Nov 2019 03:23:21 -0800 (PST) Received: from localhost.localdomain.localdomain (li541-253.members.linode.com. [198.74.49.253]) by smtp.gmail.com with ESMTPSA id d22sm8260877pjd.2.2019.11.25.03.23.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 25 Nov 2019 03:23:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1574681017; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=01mfmHmc3pZQbbO1Ft9wsZqQ9+Pv983dQjJgkVggzz0=; b=RweLGAECyYI49Bjg+i/R9alIXPUCSG3KynxkWGTTAKSYMei4M5NovVWdBcp8CJ2kTFddid /GdQPSlGOrdfR9OehD9JnDeqLvGcr54I7lN9SLW5RwWeg6VIOMRTWP+wqPPE1pI+/MiI8J PC7/xw/BMoMTiLxOG1lYtZdmrQI4vgQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=FyRh1oh2sMMvddmSgcGrSUvHZyrnpMtSKbQKzJCvMJg=; b=JUwIloRabPatv7qQJOHPAMqfgdOT39e6irzpYBrasnMa1vo5aNqvgi9x8+SWzQMic1 CZRPZorS2uzifYWlnI0jBH05Ttp/HpERd6IkwcL0bDQdc1yGy3YxE2GHG6HxKs+6lHWT MEhW3g6bI1WZ+MzeuwlC4Vz7P1AoJ+jo2JtbPWZrcygpMoedMX92w4MBbztUTyVbIQnV L5zR/1KDZ2G1gPMACn6W0Vf2dzEGPv5dQ7KJNXDDM5ykxDnYUv1DsInXjjYuW7E+eZBw +xS6I3yNo/bEbN/3LIxIUOLxhxVgmZfCdjHds5QX1t49HO5XhJ1rsRv+2oPRMZaUOeqf BYCQ== X-Gm-Message-State: APjAAAVVw9firlJvBSw/Fsl2et+FqgAIk6Qhagj/ZHvYVBHjOHpgK3d8 CZXg+cpnFxOja/9I7+jJa7aM/v6v X-Google-Smtp-Source: APXvYqwMUaxGci/dpXYRFKF83gHKm96oVeH31o8V+MwVRk6ZlY7unw8vyHnMvoR11yC6nqEbt0VcnA== X-Received: by 2002:a17:90b:4006:: with SMTP id ie6mr38047060pjb.50.1574681000058; Mon, 25 Nov 2019 03:23:20 -0800 (PST) From: LanceLiu To: libvir-list@redhat.com Date: Mon, 25 Nov 2019 19:23:07 +0800 Message-Id: <1574680987-96776-1-git-send-email-liu.lance.89@gmail.com> X-MC-Unique: jGZ7cZQIN465b_bxASfVrw-1 X-MC-Unique: ffcHOtCGMQCSa4eqn-4I2w-1 X-Scanned-By: MIMEDefang 2.78 on 10.11.54.4 X-MIME-Autoconverted: from quoted-printable to 8bit by lists01.pubmisc.prod.ext.phx2.redhat.com id xAPBNSDq012840 X-loop: libvir-list@redhat.com Cc: mprivozn@redhat.com, LanceLiu Subject: [libvirt] [PATCH] Use virNetServerClientImmediateClose() rather than virNetServerClientClose() 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 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Mimecast-Spam-Score: 0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" --- src/remote/remote_daemon_stream.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/remote/remote_daemon_stream.c b/src/remote/remote_daemon_s= tream.c index de0dca3..d206d12 100644 --- a/src/remote/remote_daemon_stream.c +++ b/src/remote/remote_daemon_stream.c @@ -141,7 +141,7 @@ daemonStreamEvent(virStreamPtr st, int events, void *op= aque) (events & VIR_STREAM_EVENT_WRITABLE)) { if (daemonStreamHandleWrite(client, stream) < 0) { daemonRemoveClientStream(client, stream); - virNetServerClientClose(client); + virNetServerClientImmediateClose(client); goto cleanup; } } @@ -151,7 +151,7 @@ daemonStreamEvent(virStreamPtr st, int events, void *op= aque) events =3D events & ~(VIR_STREAM_EVENT_READABLE); if (daemonStreamHandleRead(client, stream) < 0) { daemonRemoveClientStream(client, stream); - virNetServerClientClose(client); + virNetServerClientImmediateClose(client); goto cleanup; } /* If we detected EOF during read processing, @@ -176,7 +176,7 @@ daemonStreamEvent(virStreamPtr st, int events, void *op= aque) if (daemonStreamHandleFinish(client, stream, msg) < 0) { virNetMessageFree(msg); daemonRemoveClientStream(client, stream); - virNetServerClientClose(client); + virNetServerClientImmediateClose(client); goto cleanup; } break; @@ -186,7 +186,7 @@ daemonStreamEvent(virStreamPtr st, int events, void *op= aque) if (daemonStreamHandleAbort(client, stream, msg) < 0) { virNetMessageFree(msg); daemonRemoveClientStream(client, stream); - virNetServerClientClose(client); + virNetServerClientImmediateClose(client); goto cleanup; } break; @@ -205,7 +205,7 @@ daemonStreamEvent(virStreamPtr st, int events, void *op= aque) stream->recvEOF =3D true; if (!(msg =3D virNetMessageNew(false))) { daemonRemoveClientStream(client, stream); - virNetServerClientClose(client); + virNetServerClientImmediateClose(client); goto cleanup; } msg->cb =3D daemonStreamMessageFinished; @@ -219,7 +219,7 @@ daemonStreamEvent(virStreamPtr st, int events, void *op= aque) "", 0) < 0) { virNetMessageFree(msg); daemonRemoveClientStream(client, stream); - virNetServerClientClose(client); + virNetServerClientImmediateClose(client); goto cleanup; } } @@ -262,7 +262,7 @@ daemonStreamEvent(virStreamPtr st, int events, void *op= aque) } daemonRemoveClientStream(client, stream); if (ret < 0) - virNetServerClientClose(client); + virNetServerClientImmediateClose(client); goto cleanup; } =20 --=20 1.8.3.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list