diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-03-22 00:07:34 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-03-22 00:07:34 +0100 |
commit | 23a376f98c5dcfc392d47e8d1872884ff44e585d (patch) | |
tree | dbe476151bbd6530369c40746f2ec2365f7b500a /drivers/isdn/i4l | |
parent | driver: tty: vt: remove cast for kmalloc return value (diff) | |
parent | Linux 3.9-rc3 (diff) | |
download | linux-23a376f98c5dcfc392d47e8d1872884ff44e585d.tar.xz linux-23a376f98c5dcfc392d47e8d1872884ff44e585d.zip |
Merge 3.9-rc3 into tty-next
Diffstat (limited to 'drivers/isdn/i4l')
-rw-r--r-- | drivers/isdn/i4l/isdn_tty.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/isdn/i4l/isdn_tty.c b/drivers/isdn/i4l/isdn_tty.c index 221076628585..b72afd81a7bb 100644 --- a/drivers/isdn/i4l/isdn_tty.c +++ b/drivers/isdn/i4l/isdn_tty.c @@ -902,7 +902,9 @@ isdn_tty_send_msg(modem_info *info, atemu *m, char *msg) int j; int l; - l = strlen(msg); + l = min(strlen(msg), sizeof(cmd.parm) - sizeof(cmd.parm.cmsg) + + sizeof(cmd.parm.cmsg.para) - 2); + if (!l) { isdn_tty_modem_result(RESULT_ERROR, info); return; |