linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [BUG]drivers: usb: serial: mos7840.c: dangling pointer in function mos7840_open
@ 2021-08-01  9:03 nil Yi
  2021-08-01 12:15 ` Greg KH
  0 siblings, 1 reply; 4+ messages in thread
From: nil Yi @ 2021-08-01  9:03 UTC (permalink / raw)
  To: johan, linux-usb

Hi, there is a dangling pointer in mos7840_port->write_urb_pool[j]  in function
mos7840_open in v5.14-rc3.

in function mos7840_open err path :

717: err:
718: for (j = 0; j < NUM_URBS; ++j) {
719: urb = mos7840_port->write_urb_pool[j];
720:  if (!urb)
721:     continue;
722: kfree(urb->transfer_buffer);
723:  usb_free_urb(urb);
}

leave a dangling pointer here,  I'm not sure whether it  can be
triggered somewhere.

Any feedback would be appreciated, thanks :)


Best wishes,
Nil Yi

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-08-07  5:20 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-01  9:03 [BUG]drivers: usb: serial: mos7840.c: dangling pointer in function mos7840_open nil Yi
2021-08-01 12:15 ` Greg KH
2021-08-07  3:45   ` nil Yi
2021-08-07  5:20     ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).