public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@suse.de>
To: Toby Milne <toby@svector.co.uk>
Cc: linux-kernel@vger.kernel.org, Alan Cox <alan@lxorguk.ukuu.org.uk>
Subject: Re: [PATCH] 2.4.10-ac9 CDRW Packet Fix
Date: Wed, 10 Oct 2001 08:41:57 +0200	[thread overview]
Message-ID: <20011010084157.B3254@suse.de> (raw)
In-Reply-To: <E15qgFQ-0004pk-00@avalon.svector.gotadsl.co.uk>
In-Reply-To: <E15qgFQ-0004pk-00@avalon.svector.gotadsl.co.uk>

On Mon, Oct 08 2001, Toby Milne wrote:
> The ac tree is missing some braces - without these the userspace buffer 
> contents never get copied into the kernel buffer.
> 
> --- linux/drivers/cdrom/cdrom.c	Mon Oct  8 19:20:56 2001
> +++ linux-2.4.10-ac9/drivers/cdrom/cdrom.c	Mon Oct  8 19:19:04 2001
> @@ -1983,10 +1983,10 @@
>  	if (usense && !access_ok(VERIFY_WRITE, usense, sizeof(*usense)))
>  		goto out;
> 
> -	if (cgc->data_direction == CGC_DATA_READ)
> +	if (cgc->data_direction == CGC_DATA_READ) {
>  		if (!access_ok(VERIFY_READ, ubuf, cgc->buflen))
>  			goto out;
> -	else if (cgc->data_direction == CGC_DATA_WRITE)
> +	} else if (cgc->data_direction == CGC_DATA_WRITE)
>  		if (copy_from_user(cgc->buffer, ubuf, cgc->buflen))
>  			goto out;

Thanks, definitely a braino!

-- 
Jens Axboe


      reply	other threads:[~2001-10-10  6:41 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-10-08 19:35 [PATCH] 2.4.10-ac9 CDRW Packet Fix Toby Milne
2001-10-10  6:41 ` Jens Axboe [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=20011010084157.B3254@suse.de \
    --to=axboe@suse.de \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=toby@svector.co.uk \
    /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