From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37994) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bGIel-0001Yk-Sh for qemu-devel@nongnu.org; Fri, 24 Jun 2016 00:23:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bGIeh-0001ev-Ie for qemu-devel@nongnu.org; Fri, 24 Jun 2016 00:23:50 -0400 Received: from mx1.redhat.com ([209.132.183.28]:39747) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bGIeh-0001eM-9v for qemu-devel@nongnu.org; Fri, 24 Jun 2016 00:23:47 -0400 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 9D873627E3 for ; Fri, 24 Jun 2016 04:23:46 +0000 (UTC) References: <20160623000809.4522-1-marcandre.lureau@redhat.com> <20160623000809.4522-5-marcandre.lureau@redhat.com> From: Eric Blake Message-ID: <576CB5D1.8080309@redhat.com> Date: Thu, 23 Jun 2016 22:23:45 -0600 MIME-Version: 1.0 In-Reply-To: <20160623000809.4522-5-marcandre.lureau@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="33SDaSbUx4WGcvUa4fxBi9PCkR0SJ8FiQ" Subject: Re: [Qemu-devel] [PATCH 04/12] monitor: remove usage of generated marshal functions List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: marcandre.lureau@redhat.com, qemu-devel@nongnu.org Cc: armbru@redhat.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --33SDaSbUx4WGcvUa4fxBi9PCkR0SJ8FiQ From: Eric Blake To: marcandre.lureau@redhat.com, qemu-devel@nongnu.org Cc: armbru@redhat.com Message-ID: <576CB5D1.8080309@redhat.com> Subject: Re: [PATCH 04/12] monitor: remove usage of generated marshal functions References: <20160623000809.4522-1-marcandre.lureau@redhat.com> <20160623000809.4522-5-marcandre.lureau@redhat.com> In-Reply-To: <20160623000809.4522-5-marcandre.lureau@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 06/22/2016 06:08 PM, marcandre.lureau@redhat.com wrote: > From: Marc-Andr=C3=A9 Lureau >=20 > Once the middle mode is removed, the generated marshal functions will n= o > longer be exported. >=20 > Signed-off-by: Marc-Andr=C3=A9 Lureau > --- > monitor.c | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) >=20 > diff --git a/monitor.c b/monitor.c > index fc691b9..585bc1f 100644 > --- a/monitor.c > +++ b/monitor.c > @@ -3609,21 +3609,21 @@ static int monitor_can_read(void *opaque) > return (mon->suspend_cnt =3D=3D 0) ? 1 : 0; > } > =20 > -static bool invalid_qmp_mode(const Monitor *mon, const mon_cmd_t *cmd,= > +static bool invalid_qmp_mode(const Monitor *mon, const gchar *cmd, Why 'gchar'? What's wrong with 'char'? (Some of glib's typedefs make sense, but gchar is not one of them) > @@ -3914,7 +3914,7 @@ static void handle_qmp_command(JSONMessageParser = *parser, GQueue *tokens) > "The command %s has not been found", cmd_name); > goto err_out; > } > - if (invalid_qmp_mode(mon, cmd, &local_err)) { > + if (invalid_qmp_mode(mon, cmd_name, &local_err)) { > goto err_out; Particularly since cmd_name is const char * in the caller. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --33SDaSbUx4WGcvUa4fxBi9PCkR0SJ8FiQ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJXbLXRAAoJEKeha0olJ0Nqb2EH/jvUVT/W+Zk4HFGfIKgxH4c4 Nt/P+HNXdBmQeS+y+68DYGGhH6SGbzl/7p6H7LJZkuAXI6VLpGQyC+vJaMz67TGg 8J3Z3DI9Yi81XqkG1MEaLObEkizIR7g9pU8JjJxJWNEq6NXHjnBR7xVonxf6rEDJ aZKTaZ10ZVjIDkqlfNqx+gdbiwvlsJSEjKMGWGVLQ6dEM43WbdH4HY8CVvXe9w2V 2Qj8wMpGkIR9FnHoJ66czMpEePs2l12QRXqLt56o14giJNd6YN/XAUvQ+VrOBNzs 2DMtxqy/YRm6Sf8NYT7Gi1MGl2Xf8IQuEJCwfYzIcpJEPXjQFjytyGDsB/vUDIg= =/i69 -----END PGP SIGNATURE----- --33SDaSbUx4WGcvUa4fxBi9PCkR0SJ8FiQ--