The Linux Kernel Mailing List
 help / color / mirror / Atom feed
* [Patch] Ignored return value in drivers/mtd/chips/sharp.c
@ 2006-06-21 20:07 Eric Sesterhenn
  0 siblings, 0 replies; only message in thread
From: Eric Sesterhenn @ 2006-06-21 20:07 UTC (permalink / raw)
  To: linux-kernel; +Cc: ds

hi,

coverity (id #10) spotted that we never reach the return ret; statement,
since ret never gets assigned a value except the 0 at
initialisation. I assume it was meant to hold the result
of sharp_write_oneword().

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>

--- linux-2.6/drivers/mtd/chips/sharp.c.orig	2006-06-21 22:03:45.000000000 +0200
+++ linux-2.6/drivers/mtd/chips/sharp.c	2006-06-21 22:04:48.000000000 +0200
@@ -342,7 +342,8 @@ static int sharp_write(struct mtd_info *
 			len--;
 			j++;
 		}
-		sharp_write_oneword(map, &sharp->chips[chipnum], ofs&~3, tbuf.l);
+		ret = sharp_write_oneword(map, &sharp->chips[chipnum],
+						ofs&~3, tbuf.l);
 		if(ret<0)
 			return ret;
 		(*retlen)+=j;



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-06-21 20:07 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-06-21 20:07 [Patch] Ignored return value in drivers/mtd/chips/sharp.c Eric Sesterhenn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox