summaryrefslogtreecommitdiffstats
path: root/common/cmd_ubi.c
diff options
context:
space:
mode:
authorMarek Vasut <marek.vasut@gmail.com>2011-09-30 12:13:25 +0200
committerWolfgang Denk <wd@denx.de>2011-10-01 23:34:21 +0200
commit2984fd1673fd76de0182c9626c3d66ea2e0486e7 (patch)
treeccf96b425cd0468d17b511f0b16596a4adfae0a3 /common/cmd_ubi.c
parentcac952ffe3196cb7b1508237bb29d7161e1368c8 (diff)
downloadtalos-obmc-uboot-2984fd1673fd76de0182c9626c3d66ea2e0486e7.tar.gz
talos-obmc-uboot-2984fd1673fd76de0182c9626c3d66ea2e0486e7.zip
GCC4.6: Squash warning in cmd_ubi.c:
cmd_ubi.c: In function ‘ubi_volume_read’: cmd_ubi.c:319:9: warning: variable ‘count_save’ set but not used [-Wunused-but-set-variable] Signed-off-by: Marek Vasut <marek.vasut@gmail.com> Acked-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'common/cmd_ubi.c')
-rw-r--r--common/cmd_ubi.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/common/cmd_ubi.c b/common/cmd_ubi.c
index 629758fdf5..8c1bc23a5a 100644
--- a/common/cmd_ubi.c
+++ b/common/cmd_ubi.c
@@ -316,7 +316,6 @@ static int ubi_volume_write(char *volume, void *buf, size_t size)
static int ubi_volume_read(char *volume, char *buf, size_t size)
{
int err, lnum, off, len, tbuf_size;
- size_t count_save = size;
void *tbuf;
unsigned long long tmp;
struct ubi_volume *vol;
@@ -347,7 +346,7 @@ static int ubi_volume_read(char *volume, char *buf, size_t size)
if (vol->corrupted)
printf("read from corrupted volume %d", vol->vol_id);
if (offp + size > vol->used_bytes)
- count_save = size = vol->used_bytes - offp;
+ size = vol->used_bytes - offp;
tbuf_size = vol->usable_leb_size;
if (size < tbuf_size)
OpenPOWER on IntegriCloud