From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dario Faggioli Subject: Re: [PATCH 8/9] xl: Improve return and exit codes main_button_press(), main_trigger(), main_remus() and related functions. Date: Thu, 25 Feb 2016 12:26:03 +0100 Message-ID: <1456399563.6288.95.camel@citrix.com> References: <1456318407-3635-1-git-send-email-write.harmandeep@gmail.com> <1456318407-3635-9-git-send-email-write.harmandeep@gmail.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============4633208341865268331==" Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.84) (envelope-from ) id 1aYu3m-0007Et-K9 for xen-devel@lists.xenproject.org; Thu, 25 Feb 2016 11:26:18 +0000 In-Reply-To: <1456318407-3635-9-git-send-email-write.harmandeep@gmail.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" To: Harmandeep Kaur , xen-devel@lists.xenproject.org Cc: wei.liu2@citrix.com, ian.jackson@eu.citrix.com, ian.campbell@citrix.com, stefano.stabellini@eu.citrix.com List-Id: xen-devel@lists.xenproject.org --===============4633208341865268331== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-TFjqLBYsQp+UCYzYASt+" --=-TFjqLBYsQp+UCYzYASt+ Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, 2016-02-24 at 18:23 +0530, Harmandeep Kaur wrote: > Signed-off-by: Harmandeep Kaur > About the subject lines: try to make them more abstract. It does not scale to list all the changed functions! :-) So, in this case, something like (just out of the top of my head!) "debugging, special keys and triggering related functions". And main_remus() does not really belong here, while main_sysrq(), main_trigger(), and probably even main_debug_keys() and main_dmesg() can well do. > --- > =C2=A0tools/libxl/xl_cmdimpl.c | 16 ++++++++-------- > =C2=A01 file changed, 8 insertions(+), 8 deletions(-) >=20 > diff --git a/tools/libxl/xl_cmdimpl.c b/tools/libxl/xl_cmdimpl.c > index f7f7d7f..9e0a467 100644 > --- a/tools/libxl/xl_cmdimpl.c > +++ b/tools/libxl/xl_cmdimpl.c > @@ -374,7 +374,7 @@ static void xvasprintf(char **strp, const char > *fmt, va_list ap) > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0int r =3D vasprintf(strp, fmt, ap); > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0if (r =3D=3D -1) { > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0perror("asprintf fa= iled"); > -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0exit(-ERROR_FAIL); > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0exit(EXIT_FAILURE); > xvasprintf() doesn't fit here either. Regards, Dario --=20 <> (Raistlin Majere) ----------------------------------------------------------------- Dario Faggioli, Ph.D, http://about.me/dario.faggioli Senior Software Engineer, Citrix Systems R&D Ltd., Cambridge (UK) --=-TFjqLBYsQp+UCYzYASt+ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEABECAAYFAlbO5MsACgkQk4XaBE3IOsSxuwCgqUuJ1gl9FpL6vjlFUzGZa22A hrEAnRvHdM6hg4hkkJuzUaZVNORgN9yz =Xn96 -----END PGP SIGNATURE----- --=-TFjqLBYsQp+UCYzYASt+-- --===============4633208341865268331== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KWGVuLWRldmVs IG1haWxpbmcgbGlzdApYZW4tZGV2ZWxAbGlzdHMueGVuLm9yZwpodHRwOi8vbGlzdHMueGVuLm9y Zy94ZW4tZGV2ZWwK --===============4633208341865268331==--