diff mbox series

syz test

Message ID 20250423112029.189032-1-contact@arnaud-lcm.com
State New
Headers show
Series syz test | expand

Commit Message

Arnaud Lecomte April 23, 2025, 11:20 a.m. UTC
#syz test

--
diff mbox series

Patch

--- a/net/bluetooth/coredump.c
+++ b/net/bluetooth/coredump.c
@@ -249,6 +249,11 @@  static void hci_devcd_dump(struct hci_dev *hdev)
 
        size = hdev->dump.tail - hdev->dump.head;
 
+       if (size >SKB_MAX_ALLOC) {
+               bt_dev_err(hdev, "Dump too large (%u bytes)", size);
+               return;
+       }
+
        /* Emit a devcoredump with the available data */
        dev_coredumpv(&hdev->dev, hdev->dump.head, size, GFP_KERNEL);