From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46339) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d1DuK-0006SZ-O6 for qemu-devel@nongnu.org; Thu, 20 Apr 2017 11:22:09 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d1DuJ-0007vw-P8 for qemu-devel@nongnu.org; Thu, 20 Apr 2017 11:22:08 -0400 Date: Thu, 20 Apr 2017 11:21:59 -0400 From: Jeff Cody Message-ID: <20170420152159.GA3676@localhost.localdomain> References: <20170420040003.31074-1-famz@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170420040003.31074-1-famz@redhat.com> Subject: Re: [Qemu-devel] [PATCH] sheepdog: Set error when connection fails List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Fam Zheng Cc: qemu-devel@nongnu.org, sheepdog@lists.wpkg.org, qemu-block@nongnu.org, Hitoshi Mitake , Kevin Wolf , Max Reitz , Liu Yuan On Thu, Apr 20, 2017 at 12:00:03PM +0800, Fam Zheng wrote: > Signed-off-by: Fam Zheng > --- > block/sheepdog.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/block/sheepdog.c b/block/sheepdog.c > index fb9203e..7e889ee 100644 > --- a/block/sheepdog.c > +++ b/block/sheepdog.c > @@ -608,6 +608,7 @@ static int connect_to_sdog(BDRVSheepdogState *s, Error **errp) > qemu_set_nonblock(fd); > } else { > fd = -EIO; > + error_setg(errp, "Failed to connect to sheepdog server"); > } A bit odd that we don't just return right away in this function after a failed called to socket_connect(), but that has nothing to do with your patch. Reviewed-by: Jeff Cody > > return fd; > -- > 2.9.3 >