From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49013) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eupu6-00055k-1B for qemu-devel@nongnu.org; Sat, 10 Mar 2018 20:36:02 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eupu2-0005gw-US for qemu-devel@nongnu.org; Sat, 10 Mar 2018 20:36:02 -0500 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:53090 helo=mx1.redhat.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eupu2-0005gj-Hf for qemu-devel@nongnu.org; Sat, 10 Mar 2018 20:35:58 -0500 References: <20180309090006.10018-1-peterx@redhat.com> <20180309090006.10018-12-peterx@redhat.com> From: Eric Blake Message-ID: Date: Sat, 10 Mar 2018 19:35:43 -0600 MIME-Version: 1.0 In-Reply-To: <20180309090006.10018-12-peterx@redhat.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v8 11/23] monitor: introduce monitor_qmp_respond() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Xu , qemu-devel@nongnu.org Cc: Stefan Hajnoczi , "Daniel P . Berrange" , Paolo Bonzini , Fam Zheng , Juan Quintela , mdroth@linux.vnet.ibm.com, Laurent Vivier , Markus Armbruster , marcandre.lureau@redhat.com, "Dr . David Alan Gilbert" On 03/09/2018 02:59 AM, Peter Xu wrote: > A tiny refactoring, preparing to split the QMP dispatcher away. > > Reviewed-by: Fam Zheng > Reviewed-by: Stefan Hajnoczi > Signed-off-by: Peter Xu > --- > monitor.c | 50 +++++++++++++++++++++++++++++++++----------------- > 1 file changed, 33 insertions(+), 17 deletions(-) > > + if (rsp) { > + if (id) { > + /* This is for the qdict below. */ > + qobject_incref(id); > + qdict_put_obj(qobject_to_qdict(rsp), "id", id); Another victim of qobject_to() refactoring. Fixing that is minor, so Reviewed-by: Eric Blake -- Eric Blake, Principal Software Engineer Red Hat, Inc. +1-919-301-3266 Virtualization: qemu.org | libvirt.org