ide: Remove unneeded null pointer check

With bm == NULL, other code in the same function would crash.

This bug was reported by cppcheck:
hw/ide/pci.c:280: error: Possible null pointer dereference: bm

Cc: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Stefan Weil <weil@mail.berlios.de>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
Stefan Weil 2011-01-15 19:01:03 +01:00 committed by Kevin Wolf
parent 3de0a2944b
commit 1635eecc41

View file

@ -267,9 +267,7 @@ static void bmdma_irq(void *opaque, int n, int level)
return;
}
if (bm) {
bm->status |= BM_STATUS_INT;
}
bm->status |= BM_STATUS_INT;
/* trigger the real irq */
qemu_set_irq(bm->irq, level);