X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=net%2Fbluetooth%2Frfcomm%2Ftty.c;h=bd8d671a0ba6f1622ee54e463c2d393b0a6a8943;hb=b219e3ac66183fc9771b94af931fb5fd41d586ec;hp=2ff2d5b87c933ce92207400de962f5edba04f4ea;hpb=9262e9149f346a5443300f8c451b8e7631e81a42;p=deliverable%2Flinux.git diff --git a/net/bluetooth/rfcomm/tty.c b/net/bluetooth/rfcomm/tty.c index 2ff2d5b87c93..bd8d671a0ba6 100644 --- a/net/bluetooth/rfcomm/tty.c +++ b/net/bluetooth/rfcomm/tty.c @@ -169,10 +169,9 @@ static int rfcomm_dev_add(struct rfcomm_dev_req *req, struct rfcomm_dlc *dlc) BT_DBG("id %d channel %d", req->dev_id, req->channel); - dev = kmalloc(sizeof(struct rfcomm_dev), GFP_KERNEL); + dev = kzalloc(sizeof(struct rfcomm_dev), GFP_KERNEL); if (!dev) return -ENOMEM; - memset(dev, 0, sizeof(struct rfcomm_dev)); write_lock_bh(&rfcomm_dev_lock);