aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/tty/tty_io.c
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2012-07-24 07:51:52 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-08-10 15:54:27 -0400
commit4ac5d7050e4e4d63751e78fb152a274d05c08563 (patch)
tree385913c951b9d69361ae195f5817d2601473d770 /drivers/tty/tty_io.c
parent6b9563a714138dc2377c500e588e31f7166c92f0 (diff)
tty: fix missing assignment
We're trying to save the termios state and we need to allocate a buffer to do it. Smatch complains that the buffer is leaked at the end of the function. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/tty_io.c')
-rw-r--r--drivers/tty/tty_io.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/tty/tty_io.c b/drivers/tty/tty_io.c
index c6f4d711771b..608749978df4 100644
--- a/drivers/tty/tty_io.c
+++ b/drivers/tty/tty_io.c
@@ -1450,6 +1450,7 @@ void tty_free_termios(struct tty_struct *tty)
1450 pr_warn("tty: no memory to save termios state.\n"); 1450 pr_warn("tty: no memory to save termios state.\n");
1451 return; 1451 return;
1452 } 1452 }
1453 tty->driver->termios[idx] = tp;
1453 } 1454 }
1454 *tp = tty->termios; 1455 *tp = tty->termios;
1455} 1456}