Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

uwb: fix memory leak in uwb_rc_notif()

Don't leak memory in uwb_rc_notif() if certain non-standard events are
received.

Signed-off-by: David Vrabel <david.vrabel@csr.com>

+1 -18
+1 -18
drivers/uwb/neh.c
··· 349 349 } 350 350 351 351 352 - /** 352 + /* 353 353 * Process notifications coming from the radio control interface 354 354 * 355 355 * @rc: UWB Radio Control Interface descriptor ··· 400 400 uwb_evt->type = UWB_EVT_TYPE_NOTIF; 401 401 uwb_evt->notif.size = size; 402 402 uwb_evt->notif.rceb = rceb; 403 - 404 - switch (le16_to_cpu(rceb->wEvent)) { 405 - /* Trap some vendor specific events 406 - * 407 - * FIXME: move this to handling in ptc-est, where we 408 - * register a NULL event handler for these two guys 409 - * using the Intel IDs. 410 - */ 411 - case 0x0103: 412 - dev_info(dev, "FIXME: DEVICE ADD\n"); 413 - return; 414 - case 0x0104: 415 - dev_info(dev, "FIXME: DEVICE RM\n"); 416 - return; 417 - default: 418 - break; 419 - } 420 403 421 404 uwbd_event_queue(uwb_evt); 422 405 }