From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:46658) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UJAnY-0002n3-Hv for qemu-devel@nongnu.org; Fri, 22 Mar 2013 18:50:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UJAnX-0002co-Lv for qemu-devel@nongnu.org; Fri, 22 Mar 2013 18:50:56 -0400 Received: from mail-wi0-x22e.google.com ([2a00:1450:400c:c05::22e]:65272) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UJAnX-0002ch-EF for qemu-devel@nongnu.org; Fri, 22 Mar 2013 18:50:55 -0400 Received: by mail-wi0-f174.google.com with SMTP id hj8so284577wib.1 for ; Fri, 22 Mar 2013 15:50:54 -0700 (PDT) Sender: Paolo Bonzini Message-ID: <514CE04A.30608@redhat.com> Date: Fri, 22 Mar 2013 23:50:50 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1363974083-28440-1-git-send-email-kwolf@redhat.com> <1363974083-28440-9-git-send-email-kwolf@redhat.com> In-Reply-To: <1363974083-28440-9-git-send-email-kwolf@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 08/14] nbd: Accept -drive options for the network connection List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: qemu-devel@nongnu.org, anthony@codemonkey.ws Il 22/03/2013 18:41, Kevin Wolf ha scritto: > + > + if (qdict_haskey(options, "path")) { > + s->is_unix = true; > + } else if (qdict_haskey(options, "host")) { > + s->is_unix = false; > + } else { > + return -EINVAL; > } > - return err; > + > + s->socket_opts = qemu_opts_create_nofail(&socket_optslist); > + > + qemu_opts_absorb_qdict(s->socket_opts, options, &local_err); Similarly, this should create a SocketAddress and then just use socket_connect. Paolo