diff options
author | Gerd Hoffmann <kraxel@redhat.com> | 2010-03-29 15:42:57 +0200 |
---|---|---|
committer | Aurelien Jarno <aurelien@aurel32.net> | 2010-04-18 22:02:30 +0200 |
commit | 3597c9c1d5722edf1ebcaf01ff1ea7c3b68ecb28 (patch) | |
tree | 804f6958738a38d3a3c3411575137a7c36e7037d /hw/lsi53c895a.c | |
parent | lsi: pass lsi_request to lsi_reselect (diff) | |
download | qemu-kvm-3597c9c1d5722edf1ebcaf01ff1ea7c3b68ecb28.tar.gz qemu-kvm-3597c9c1d5722edf1ebcaf01ff1ea7c3b68ecb28.tar.bz2 qemu-kvm-3597c9c1d5722edf1ebcaf01ff1ea7c3b68ecb28.zip |
lsi: fix segfault in lsi_command_complete
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
(cherry picked from commit 6ac08101f9de84be1fb7b45f87caed8ba8f3eb5a)
Diffstat (limited to 'hw/lsi53c895a.c')
-rw-r--r-- | hw/lsi53c895a.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/lsi53c895a.c b/hw/lsi53c895a.c index 872106d1e..e0ade1e54 100644 --- a/hw/lsi53c895a.c +++ b/hw/lsi53c895a.c @@ -679,7 +679,7 @@ static void lsi_command_complete(SCSIBus *bus, int reason, uint32_t tag, return; } - if (s->waiting == 1 || tag != s->current->tag || + if (s->waiting == 1 || !s->current || tag != s->current->tag || (lsi_irq_on_rsl(s) && !(s->scntl1 & LSI_SCNTL1_CON))) { if (lsi_queue_tag(s, tag, arg)) return; |