Re: [Patch 7/9] fs/exec.c: fix wrong return value ofprepare_binprm()

From: Al Viro
Date: Sat May 10 2008 - 15:31:23 EST


On Thu, May 08, 2008 at 09:52:32PM +0800, WANG Cong wrote:
> All prepare_binprm()'s callers assume that prepare_binprm() fails
> when it returns negative. However, prepare_binprm() most probably returns
> the return value of kernel_read(), which may return positive on failure!
>
> Thus this should be fixed.

Since when does read return positive on failure?
--
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/