From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54729) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YNh3X-0005NF-IT for qemu-devel@nongnu.org; Tue, 17 Feb 2015 07:15:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YNh3U-00062l-C1 for qemu-devel@nongnu.org; Tue, 17 Feb 2015 07:15:11 -0500 Received: from mx1.redhat.com ([209.132.183.28]:43680) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YNh3U-00062G-57 for qemu-devel@nongnu.org; Tue, 17 Feb 2015 07:15:08 -0500 From: Markus Armbruster References: <1421067237-6955-1-git-send-email-kraxel@redhat.com> <1421067237-6955-5-git-send-email-kraxel@redhat.com> <87k2zly8hf.fsf@blackfin.pond.sub.org> <1424163494.6014.24.camel@nilsson.home.kraxel.org> Date: Tue, 17 Feb 2015 13:15:03 +0100 In-Reply-To: <1424163494.6014.24.camel@nilsson.home.kraxel.org> (Gerd Hoffmann's message of "Tue, 17 Feb 2015 09:58:14 +0100") Message-ID: <877fvgka48.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [PATCH 04/10] vnc: switch to QemuOpts, allow multiple servers List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gerd Hoffmann Cc: Paolo Bonzini , qemu-devel@nongnu.org, Anthony Liguori , Luiz Capitulino Gerd Hoffmann writes: > Hi, > >> > static void qmp_change_vnc_listen(const char *target, Error **errp) >> > { >> > - vnc_display_open(NULL, target, errp); >> > + QemuOptsList *olist = qemu_find_opts("vnc"); >> > + QemuOpts *opts; >> > + >> > + if (strstr(target, "id=")) { >> > + error_setg(errp, "id not supported"); >> > + return; >> > + } >> >> Aside: this is unclean. Could we somehow test qemu_opts_id() instead? > > For that we would have to parse it first, which has some ugly corner > cases on id clashes ... > > All I wanna do here is keep it alive for the existing use cases, without > support for multiple displays, with minimum effort. > > Should we need support for vnc config change in a multiple vnc server > setup a new qmp monitor command should be designed for that. Fair enough. Suggests that the QemuOpts API is lacking, though.