aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/isdn/isdnloop/isdnloop.c
diff options
context:
space:
mode:
authorWu Fengguang <fengguang.wu@intel.com>2012-08-02 19:10:01 -0400
committerDavid S. Miller <davem@davemloft.net>2012-08-03 19:53:22 -0400
commit77f00f6324cb97cf1df6f9c4aaeea6ada23abdb2 (patch)
tree2fa128ec6e67e6ebaf36cc84b0138321d6e0a4a8 /drivers/isdn/isdnloop/isdnloop.c
parentae9e63bb2c0cf5437d9d13d822b27149336c6e0e (diff)
isdnloop: fix and simplify isdnloop_init()
Fix a buffer overflow bug by removing the revision and printk. [ 22.016214] isdnloop-ISDN-driver Rev 1.11.6.7 [ 22.097508] isdnloop: (loop0) virtual card added [ 22.174400] Kernel panic - not syncing: stack-protector: Kernel stack is corrupted in: ffffffff83244972 [ 22.174400] [ 22.436157] Pid: 1, comm: swapper Not tainted 3.5.0-bisect-00018-gfa8bbb1-dirty #129 [ 22.624071] Call Trace: [ 22.720558] [<ffffffff832448c3>] ? CallcNew+0x56/0x56 [ 22.815248] [<ffffffff8222b623>] panic+0x110/0x329 [ 22.914330] [<ffffffff83244972>] ? isdnloop_init+0xaf/0xb1 [ 23.014800] [<ffffffff832448c3>] ? CallcNew+0x56/0x56 [ 23.090763] [<ffffffff8108e24b>] __stack_chk_fail+0x2b/0x30 [ 23.185748] [<ffffffff83244972>] isdnloop_init+0xaf/0xb1 Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/isdn/isdnloop/isdnloop.c')
-rw-r--r--drivers/isdn/isdnloop/isdnloop.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/drivers/isdn/isdnloop/isdnloop.c b/drivers/isdn/isdnloop/isdnloop.c
index 5405ec644db3..baf2686aa8eb 100644
--- a/drivers/isdn/isdnloop/isdnloop.c
+++ b/drivers/isdn/isdnloop/isdnloop.c
@@ -16,7 +16,6 @@
16#include <linux/sched.h> 16#include <linux/sched.h>
17#include "isdnloop.h" 17#include "isdnloop.h"
18 18
19static char *revision = "$Revision: 1.11.6.7 $";
20static char *isdnloop_id = "loop0"; 19static char *isdnloop_id = "loop0";
21 20
22MODULE_DESCRIPTION("ISDN4Linux: Pseudo Driver that simulates an ISDN card"); 21MODULE_DESCRIPTION("ISDN4Linux: Pseudo Driver that simulates an ISDN card");
@@ -1494,17 +1493,6 @@ isdnloop_addcard(char *id1)
1494static int __init 1493static int __init
1495isdnloop_init(void) 1494isdnloop_init(void)
1496{ 1495{
1497 char *p;
1498 char rev[10];
1499
1500 if ((p = strchr(revision, ':'))) {
1501 strcpy(rev, p + 1);
1502 p = strchr(rev, '$');
1503 *p = 0;
1504 } else
1505 strcpy(rev, " ??? ");
1506 printk(KERN_NOTICE "isdnloop-ISDN-driver Rev%s\n", rev);
1507
1508 if (isdnloop_id) 1496 if (isdnloop_id)
1509 return (isdnloop_addcard(isdnloop_id)); 1497 return (isdnloop_addcard(isdnloop_id));
1510 1498