qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Eric Blake <eblake@redhat.com>
To: Peter Lieven <pl@kamp.de>, qemu-devel@nongnu.org
Cc: kwolf@redhat.com, pbonzini@redhat.com, ronniesahlberg@gmail.com,
	stefanha@redhat.com
Subject: Re: [Qemu-devel] [PATCHv3 1/2] block/nfs: fix url parameter checking
Date: Tue, 24 Jun 2014 17:26:52 -0600	[thread overview]
Message-ID: <53AA093C.4080103@redhat.com> (raw)
In-Reply-To: <1403647561-19534-2-git-send-email-pl@kamp.de>

[-- Attachment #1: Type: text/plain, Size: 804 bytes --]

On 06/24/2014 04:06 PM, Peter Lieven wrote:
> this patch fixes the incorrect usage of strncmp and
> adds simple error checking by means of parse_uint_full
> instead of atoi for the supplied URL parameters.
> 
> Signed-off-by: Peter Lieven <pl@kamp.de>
> ---
>  block/nfs.c |   18 ++++++++++++------
>  1 file changed, 12 insertions(+), 6 deletions(-)
> 

> +        if (parse_uint_full(qp->p[i].value, &val, 0)) {
> +            error_setg(errp, "Illegal value for NFS parameter: %s",

I prefer s/Illegal/Invalid/, as this is not a case of breaking a law.

But that's aesthetic.  Whether or not you tweak that choice of wording:

Reviewed-by: Eric Blake <eblake@redhat.com>

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 604 bytes --]

  reply	other threads:[~2014-06-24 23:27 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-24 22:05 [Qemu-devel] [PATCHv3 0/2] block/nfs: add knob to set readahead Peter Lieven
2014-06-24 22:06 ` [Qemu-devel] [PATCHv3 1/2] block/nfs: fix url parameter checking Peter Lieven
2014-06-24 23:26   ` Eric Blake [this message]
2014-06-24 22:06 ` [Qemu-devel] [PATCHv3 2/2] block/nfs: add knob to set readahead Peter Lieven
2014-06-24 23:27   ` Eric Blake
2014-06-25  8:30 ` [Qemu-devel] [PATCHv3 0/2] " Kevin Wolf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=53AA093C.4080103@redhat.com \
    --to=eblake@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=pl@kamp.de \
    --cc=qemu-devel@nongnu.org \
    --cc=ronniesahlberg@gmail.com \
    --cc=stefanha@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).