diff options
author | Marcelo Tosatti <mtosatti@redhat.com> | 2012-10-11 05:22:43 -0300 |
---|---|---|
committer | Marcelo Tosatti <mtosatti@redhat.com> | 2012-10-11 05:22:43 -0300 |
commit | a60ffef7db55339b471ebf85105eb549c9959149 (patch) | |
tree | 05d039691bbcec019327458bbccb3046044d8980 /hw/onenand.c | |
parent | caaef9b163a4696f686d91f9f2767e9c6ab446d6 (diff) | |
parent | afb63ebd0a9599312c27ecceb839a399740e00ef (diff) |
Merge commit 'afb63ebd0a9599312c27ecceb839a399740e00ef' into upstream-merge
* commit 'afb63ebd0a9599312c27ecceb839a399740e00ef':
configure: Support empty target list (--target-list=)
hw: Fix return value check for bdrv_read, bdrv_write
Conflicts:
configure
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'hw/onenand.c')
-rw-r--r-- | hw/onenand.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/onenand.c b/hw/onenand.c index db6af682c..0f7b755a6 100644 --- a/hw/onenand.c +++ b/hw/onenand.c @@ -351,7 +351,7 @@ static inline int onenand_erase(OneNANDState *s, int sec, int num) for (; num > 0; num--, sec++) { if (s->bdrv_cur) { int erasesec = s->secs_cur + (sec >> 5); - if (bdrv_write(s->bdrv_cur, sec, blankbuf, 1)) { + if (bdrv_write(s->bdrv_cur, sec, blankbuf, 1) < 0) { goto fail; } if (bdrv_read(s->bdrv_cur, erasesec, tmpbuf, 1) < 0) { |