aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/isdn/i4l/isdn_tty.c
diff options
context:
space:
mode:
authorDan Carpenter <error27@gmail.com>2010-09-04 04:33:03 -0400
committerDavid S. Miller <davem@davemloft.net>2010-09-06 21:29:19 -0400
commitf417f5e4ba79a08e992c79a4bb84c8a8c5062017 (patch)
tree4142b1329e245ad62a144e0e6fedd64554b9af00 /drivers/isdn/i4l/isdn_tty.c
parent017d79ef0073fdb170dcf185dc4c2456a304d659 (diff)
isdn: cleanup: make buffer smaller
This showed up in my audit because we use strcpy() to copy "ds" into a 32 character buffer inside the isdn_tty_dial() function. But it turns out that we only ever use the first 32 characters so it's OK. I have changed the declaration to make the static checkers happy. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/isdn/i4l/isdn_tty.c')
-rw-r--r--drivers/isdn/i4l/isdn_tty.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/isdn/i4l/isdn_tty.c b/drivers/isdn/i4l/isdn_tty.c
index 51dc60da333b..f013ee15327c 100644
--- a/drivers/isdn/i4l/isdn_tty.c
+++ b/drivers/isdn/i4l/isdn_tty.c
@@ -3515,7 +3515,7 @@ isdn_tty_parse_at(modem_info * info)
3515{ 3515{
3516 atemu *m = &info->emu; 3516 atemu *m = &info->emu;
3517 char *p; 3517 char *p;
3518 char ds[40]; 3518 char ds[ISDN_MSNLEN];
3519 3519
3520#ifdef ISDN_DEBUG_AT 3520#ifdef ISDN_DEBUG_AT
3521 printk(KERN_DEBUG "AT: '%s'\n", m->mdmcmd); 3521 printk(KERN_DEBUG "AT: '%s'\n", m->mdmcmd);
@@ -3594,7 +3594,7 @@ isdn_tty_parse_at(modem_info * info)
3594 break; 3594 break;
3595 case '3': 3595 case '3':
3596 p++; 3596 p++;
3597 sprintf(ds, "\r\n%d", info->emu.charge); 3597 snprintf(ds, sizeof(ds), "\r\n%d", info->emu.charge);
3598 isdn_tty_at_cout(ds, info); 3598 isdn_tty_at_cout(ds, info);
3599 break; 3599 break;
3600 default:; 3600 default:;