Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 211644
b: refs/heads/master
c: 84ec06c
h: refs/heads/master
v: v3
  • Loading branch information
Amit Shah authored and Rusty Russell committed Oct 21, 2010
1 parent da64643 commit d75f23a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 96eb872b2a041b1536ccc6ae2fa87eb28f6e2bb2
refs/heads/master: 84ec06c59a14d0941dd58ca6793b24a7e86b3b85
5 changes: 4 additions & 1 deletion trunk/drivers/char/virtio_console.c
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,10 @@ static ssize_t __send_control_msg(struct ports_device *portdev, u32 port_id,
static ssize_t send_control_msg(struct port *port, unsigned int event,
unsigned int value)
{
return __send_control_msg(port->portdev, port->id, event, value);
/* Did the port get unplugged before userspace closed it? */
if (port->portdev)
return __send_control_msg(port->portdev, port->id, event, value);
return 0;
}

/* Callers must take the port->outvq_lock */
Expand Down

0 comments on commit d75f23a

Please sign in to comment.