Skip to content

Commit

Permalink
tty: Fix a kref leak in the HSO driver on re-open
Browse files Browse the repository at this point in the history
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Alan Cox authored and torvalds committed Jan 15, 2009
1 parent a9fec71 commit fe41cbb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/net/usb/hso.c
Original file line number Diff line number Diff line change
Expand Up @@ -1297,6 +1297,7 @@ static int hso_serial_open(struct tty_struct *tty, struct file *filp)
/* setup */
spin_lock_irq(&serial->serial_lock);
tty->driver_data = serial;
tty_kref_put(serial->tty);
serial->tty = tty_kref_get(tty);
spin_unlock_irq(&serial->serial_lock);

Expand Down

0 comments on commit fe41cbb

Please sign in to comment.