Skip to content

Commit

Permalink
ivshmem: remove redundant assignment, fix crash with msi=off
Browse files Browse the repository at this point in the history
Fix crash when msi=false introduced in 660c97e (msi_vectors is NULL in
this case)

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
(cherry picked from commit 47213eb)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
  • Loading branch information
elmarco authored and mdroth committed Mar 15, 2016
1 parent 3e96d5d commit 702a8d1
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions hw/misc/ivshmem.c
Expand Up @@ -355,12 +355,9 @@ static CharDriverState* create_eventfd_chr_device(IVShmemState *s,
int vector)
{
/* create a event character device based on the passed eventfd */
PCIDevice *pdev = PCI_DEVICE(s);
int eventfd = event_notifier_get_fd(n);
CharDriverState *chr;

s->msi_vectors[vector].pdev = pdev;

chr = qemu_chr_open_eventfd(eventfd);

if (chr == NULL) {
Expand Down

0 comments on commit 702a8d1

Please sign in to comment.