From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43479) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yqlvz-00080Y-Pv for qemu-devel@nongnu.org; Fri, 08 May 2015 13:19:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yqlvw-00037W-AQ for qemu-devel@nongnu.org; Fri, 08 May 2015 13:19:35 -0400 Received: from cantor2.suse.de ([195.135.220.15]:41972 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yqlvw-00037S-4y for qemu-devel@nongnu.org; Fri, 08 May 2015 13:19:32 -0400 Message-ID: <554CF023.1030103@suse.de> Date: Fri, 08 May 2015 19:19:31 +0200 From: =?ISO-8859-15?Q?Andreas_F=E4rber?= MIME-Version: 1.0 References: <1430476206-26034-1-git-send-email-berrange@redhat.com> <1430476206-26034-6-git-send-email-berrange@redhat.com> In-Reply-To: <1430476206-26034-6-git-send-email-berrange@redhat.com> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v3 5/7] qom: make enum string tables const-correct List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Daniel P. Berrange" , qemu-devel@nongnu.org Cc: Paolo Bonzini Am 01.05.2015 um 12:30 schrieb Daniel P. Berrange: > The enum string table parameters in various QOM/QAPI methods > are declared 'const char *strings[]'. This results in const > warnings if passed a variable that was declared as >=20 > static const char * const strings[] =3D { .... }; >=20 > Add the extra const annotation to the parameters, since > neither the string elements, nor the array itself should > ever be modified. >=20 > Signed-off-by: Daniel P. Berrange > --- > include/hw/qdev-core.h | 2 +- > include/qapi/util.h | 2 +- > include/qapi/visitor-impl.h | 6 +++--- > include/qapi/visitor.h | 2 +- > include/qom/object.h | 2 +- > qapi/qapi-dealloc-visitor.c | 3 ++- > qapi/qapi-util.c | 2 +- > qapi/qapi-visit-core.c | 6 +++--- > qom/object.c | 2 +- > scripts/qapi-types.py | 4 ++-- > 10 files changed, 16 insertions(+), 15 deletions(-) Reviewed-by: Andreas F=E4rber Andreas --=20 SUSE Linux GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Felix Imend=F6rffer, Jane Smithard, Dilip Upmanyu, Graham Norton; HRB 21284 (AG N=FCrnberg)