Re: [PATCH] remember to check return value from __copy_to_user() in cdrom_read_cdda_old()

From: Jens Axboe
Date: Tue Sep 07 2004 - 05:01:05 EST


On Tue, Sep 07 2004, Paul Mackerras wrote:
> Jens Axboe writes:
>
> > __copy_to_user is the unchecking version of copy_to_user.
>
> It doesn't range-check the address, but it does return non-zero
> (number of bytes not copied) if it encounters a fault writing to the
> user buffer.

I don't see your point. We already access checked the range, so if
__copy_to_user() returns non-zero, the application is buggy.

--
Jens Axboe

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/