From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:51830) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbYLG-0007W2-Pv for qemu-devel@nongnu.org; Fri, 16 Dec 2011 09:00:59 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RbYLB-00032g-7R for qemu-devel@nongnu.org; Fri, 16 Dec 2011 09:00:54 -0500 Received: from mx1.redhat.com ([209.132.183.28]:6506) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbYLA-00032Z-Vm for qemu-devel@nongnu.org; Fri, 16 Dec 2011 09:00:49 -0500 Message-ID: <4EEB4F0C.7050702@redhat.com> Date: Fri, 16 Dec 2011 15:00:44 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1324036918-2405-1-git-send-email-pbonzini@redhat.com> <1324036918-2405-2-git-send-email-pbonzini@redhat.com> <4EEB4DE2.2060805@codemonkey.ws> In-Reply-To: <4EEB4DE2.2060805@codemonkey.ws> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 1/8] qapi: fix NULL pointer dereference List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: kwolf@redhat.com, qemu-devel@nongnu.org On 12/16/2011 02:55 PM, Anthony Liguori wrote: >> This is visible with >> >> qom-get path=/i440fx/piix3 property=romfile >> >> after static non-string properties are introduced. > > I'm a bit confused about what's happening here. What's the significance > of non-string properties? Should have been "static non-legacy properties". When you don't have a value for a property, legacy properties are visited as "", while the new static properties do not pass anything to the visitor. I stole this from qdev_property_get_str: value = prop->get(dev, errp); if (value) { visit_type_str(v, &value, name, errp); g_free(value); } Paolo