]> err.no Git - linux-2.6/blobdiff - drivers/isdn/i4l/isdn_net.c
Merge branch 'core/softirq' of git://git.kernel.org/pub/scm/linux/kernel/git/tip...
[linux-2.6] / drivers / isdn / i4l / isdn_net.c
index b39d1f5b378e5b06f88769a6c17566f4cf94edf5..ef1a300068dcd88fd4ef6058c2ca82bb194587c8 100644 (file)
@@ -2010,6 +2010,7 @@ isdn_net_init(struct net_device *ndev)
        ndev->flags = IFF_NOARP|IFF_POINTOPOINT;
        ndev->type = ARPHRD_ETHER;
        ndev->addr_len = ETH_ALEN;
+       ndev->validate_addr = NULL;
 
        /* for clients with MPPP maybe higher values better */
        ndev->tx_queue_len = 30;
@@ -2104,7 +2105,7 @@ isdn_net_find_icall(int di, int ch, int idx, setup_parm *setup)
        u_long flags;
        isdn_net_dev *p;
        isdn_net_phone *n;
-       char nr[32];
+       char nr[ISDN_MSNLEN];
        char *my_eaz;
 
        /* Search name in netdev-chain */
@@ -2113,7 +2114,7 @@ isdn_net_find_icall(int di, int ch, int idx, setup_parm *setup)
                nr[1] = '\0';
                printk(KERN_INFO "isdn_net: Incoming call without OAD, assuming '0'\n");
        } else
-               strcpy(nr, setup->phone);
+               strlcpy(nr, setup->phone, ISDN_MSNLEN);
        si1 = (int) setup->si1;
        si2 = (int) setup->si2;
        if (!setup->eazmsn[0]) {
@@ -2789,7 +2790,7 @@ isdn_net_setcfg(isdn_net_ioctl_cfg * cfg)
                                chidx = -1;
                        }
                }
-               strcpy(lp->msn, cfg->eaz);
+               strlcpy(lp->msn, cfg->eaz, sizeof(lp->msn));
                lp->pre_device = drvidx;
                lp->pre_channel = chidx;
                lp->onhtime = cfg->onhtime;
@@ -2936,7 +2937,7 @@ isdn_net_addphone(isdn_net_ioctl_phone * phone)
        if (p) {
                if (!(n = kmalloc(sizeof(isdn_net_phone), GFP_KERNEL)))
                        return -ENOMEM;
-               strcpy(n->num, phone->phone);
+               strlcpy(n->num, phone->phone, sizeof(n->num));
                n->next = p->local->phone[phone->outgoing & 1];
                p->local->phone[phone->outgoing & 1] = n;
                return 0;