Received: from eggs.gnu.org ([2001:4830:134:3::10]:51043) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yuh0r-0000D3-NA for qemu-devel@nongnu.org; Tue, 19 May 2015 08:52:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yuh0l-0000M2-RK for qemu-devel@nongnu.org; Tue, 19 May 2015 08:52:49 -0400 Received: from mail-wi0-x22c.google.com ([2a00:1450:400c:c05::22c]:36785) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yuh0l-0000Le-BX for qemu-devel@nongnu.org; Tue, 19 May 2015 08:52:43 -0400 Received: by wizk4 with SMTP id k4so116289829wiz.1 for ; Tue, 19 May 2015 05:52:42 -0700 (PDT) Date: Tue, 19 May 2015 13:52:39 +0100 From: Stefan Hajnoczi Message-ID: <20150519125239.GB9338@stefanha-thinkpad.redhat.com> References: <1431691143-1015-1-git-send-email-armbru@redhat.com> <1431691143-1015-9-git-send-email-armbru@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="kXdP64Ggrk/fb43R" Content-Disposition: inline In-Reply-To: <1431691143-1015-9-git-send-email-armbru@redhat.com> Subject: Re: [Qemu-devel] [PATCH v2 08/15] tap: Convert net_init_tap_one() to Error List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster Cc: eblake@redhat.co, qemu-devel@nongnu.org, stefanha@redhat.com --kXdP64Ggrk/fb43R Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Fri, May 15, 2015 at 01:58:56PM +0200, Markus Armbruster wrote: > @@ -644,30 +644,28 @@ static int net_init_tap_one(const NetdevTapOptions *tap, NetClientState *peer, > if (tap->has_vhostfd || tap->has_vhostfds) { > vhostfd = monitor_fd_param(cur_mon, vhostfdname, &err); > if (vhostfd == -1) { > - error_report_err(err); > - return -1; > + error_propagate(errp, err); > + return; > } > } else { > vhostfd = open("/dev/vhost-net", O_RDWR); > if (vhostfd < 0) { > - error_report("tap: open vhost char device failed: %s", > - strerror(errno)); > - return -1; > + error_setg_errno(errp, errno, > + "tap: open vhost char device failed: %s"); > + return; %s must be removed since error_setg_errno() already prints the error string and we have no format string argument. If there are no other issues I'll do this when merging the patch. --kXdP64Ggrk/fb43R Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJVWzIXAAoJEJykq7OBq3PI4coIAIW3ZSwaeREHsQM1wGm+88pY Y7qRZtyYMyx3ulskfKyLTOEIx4tbC2trCoHL814YEvSpECuEnVIVZd8Od94TTgtV HvBQ+RUELRDS5RUR3fT7NFvtgAxNaI7GhS5SoE6z6iGarB7YHZpbdhXqFuVWSwr6 ZS5N8/HLERjdSFW+Pm34BYn598tEJoJ36ZOwUwfn5yz1QwGAJd6zsVRPYiqX+ba1 k/Ec+irvwtIC+KNFZydeK4dkuioLd3/AT8txcXq12U2jQDdeubgTGmPSZGnJGhn7 wOXjQSViTHKr5hPrZ9bsaYEcgjtMRIgrxlZeJIP1/qU9Z6b8GfDS8liui25sJ7w= =dDzO -----END PGP SIGNATURE----- --kXdP64Ggrk/fb43R--