summaryrefslogtreecommitdiff
path: root/hw/ecc.c
diff options
context:
space:
mode:
authorStefan Weil <sw@weilnetz.de>2012-04-28 17:52:31 +0200
committerAlexander Graf <agraf@suse.de>2012-05-01 21:47:01 +0200
commit5f2c23e61a7cebed05a43dda127c83a21c681420 (patch)
tree9f66b3b125108d38aad1b43cd75c866a5588800f /hw/ecc.c
parent73f7821baca8ec063ace277539bedeb286663965 (diff)
downloadqemu-5f2c23e61a7cebed05a43dda127c83a21c681420.tar.gz
qemu-5f2c23e61a7cebed05a43dda127c83a21c681420.tar.bz2
qemu-5f2c23e61a7cebed05a43dda127c83a21c681420.zip
ppce500_spin: Replace assert by hw_error (fixes compiler warning)
The default case in function spin_read should never be reached, therefore the old code used assert(0) to abort QEMU. This does not work when QEMU is compiled with macro NDEBUG defined. In this case (and also when the compiler does not know that assert never returns), there is a compiler warning because of the missing return value. Using hw_error allows an improved error message and aborts always. Signed-off-by: Stefan Weil <sw@weilnetz.de> [agraf: use __func__] Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'hw/ecc.c')
0 files changed, 0 insertions, 0 deletions