diff options
Diffstat (limited to 'hw/misc/mac_via.c')
-rw-r--r-- | hw/misc/mac_via.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/misc/mac_via.c b/hw/misc/mac_via.c index 525e38c..c32325d 100644 --- a/hw/misc/mac_via.c +++ b/hw/misc/mac_via.c @@ -1029,8 +1029,8 @@ static void mos6522_q800_via1_realize(DeviceState *dev, Error **errp) return; } - len = blk_pread(v1s->blk, 0, v1s->PRAM, sizeof(v1s->PRAM)); - if (len != sizeof(v1s->PRAM)) { + ret = blk_pread(v1s->blk, 0, v1s->PRAM, sizeof(v1s->PRAM)); + if (ret < 0) { error_setg(errp, "can't read PRAM contents"); return; } |