Message ID | 4AD32B3F.9060804@gmail.com (mailing list archive) |
---|---|
State | Changes Requested |
Headers | show |
Roel,
> Or can this test be removed?
I'd prefer just to remove the test.
Cheers,
Jeremy
On Tuesday 13 October 2009, Jeremy Kerr wrote: > > Or can this test be removed? > > I'd prefer just to remove the test. Yes, sounds good. Arnd <><
diff --git a/arch/powerpc/platforms/cell/spufs/file.c b/arch/powerpc/platforms/cell/spufs/file.c index 884e8bc..d4f304f 100644 --- a/arch/powerpc/platforms/cell/spufs/file.c +++ b/arch/powerpc/platforms/cell/spufs/file.c @@ -2494,7 +2494,7 @@ static ssize_t spufs_switch_log_read(struct file *file, char __user *buf, struct spu_context *ctx = SPUFS_I(inode)->i_ctx; int error = 0, cnt = 0; - if (!buf || len < 0) + if (!buf || (ssize_t)len < 0) return -EINVAL; error = spu_acquire(ctx);
size_t len cannot be less than 0. Signed-off-by: Roel Kluin <roel.kluin@gmail.com> --- Or can this test be removed?