]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/blobdiff - net/bluetooth/l2cap_core.c
Bluetooth: use memset avoid memory leaks
[mirror_ubuntu-jammy-kernel.git] / net / bluetooth / l2cap_core.c
index 77ba68209dbd89d928e73d1bed9c304a1a1198e2..c57a45df7a267f8965912d4343fcc9c6a868aa06 100644 (file)
@@ -1436,6 +1436,7 @@ static void l2cap_ecred_connect(struct l2cap_chan *chan)
 
        l2cap_ecred_init(chan, 0);
 
+       memset(&data, 0, sizeof(data));
        data.pdu.req.psm     = chan->psm;
        data.pdu.req.mtu     = cpu_to_le16(chan->imtu);
        data.pdu.req.mps     = cpu_to_le16(chan->mps);