kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Will Deacon <will.deacon@arm.com>
To: "G. Campana" <gcampana+kvm@quarkslab.com>
Cc: kvm@vger.kernel.org, andre.przywara@arm.com
Subject: Re: [PATCH 4/7] kvmtool: check strncpy return value
Date: Tue, 8 Nov 2016 02:10:01 +0000	[thread overview]
Message-ID: <20161108021001.GW20591@arm.com> (raw)
In-Reply-To: <1476806576-9825-1-git-send-email-gcampana+kvm@quarkslab.com>

On Tue, Oct 18, 2016 at 06:02:56PM +0200, G. Campana wrote:
> ---
>  virtio/9p.c | 28 +++++++++++++++++++++++-----
>  1 file changed, 23 insertions(+), 5 deletions(-)
> 
> diff --git a/virtio/9p.c b/virtio/9p.c
> index cd93d06..87a579f 100644
> --- a/virtio/9p.c
> +++ b/virtio/9p.c
> @@ -424,7 +424,11 @@ static void virtio_p9_walk(struct p9_dev *p9dev,
>  	if (nwname) {
>  		struct p9_fid *fid = get_fid(p9dev, fid_val);
>  
> -		join_path(new_fid, fid->path);
> +		if (join_path(new_fid, fid->path) != 0) {
> +			errno = ENAMETOOLONG;
> +			goto err_out;
> +		}

This patch should be merged in with the introduction of join_path.

Will

      reply	other threads:[~2016-11-08  2:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-18 16:02 [PATCH 4/7] kvmtool: check strncpy return value G. Campana
2016-11-08  2:10 ` Will Deacon [this message]

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=20161108021001.GW20591@arm.com \
    --to=will.deacon@arm.com \
    --cc=andre.przywara@arm.com \
    --cc=gcampana+kvm@quarkslab.com \
    --cc=kvm@vger.kernel.org \
    /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).