]> git.karo-electronics.de Git - linux-beck.git/commit
USB: serial: mos7840: fix another NULL-deref at open
authorJohan Hovold <johan@kernel.org>
Thu, 9 Feb 2017 11:11:41 +0000 (12:11 +0100)
committerJohan Hovold <johan@kernel.org>
Thu, 9 Feb 2017 12:15:07 +0000 (13:15 +0100)
commit5182c2cf2a9bfb7f066ef0bdd2bb6330b94dd74e
tree414b05aea8dfc4e5fe15ea39804667c27cc9e8c4
parent0e517c93dc027e49d4523fe32631606b12f0752d
USB: serial: mos7840: fix another NULL-deref at open

Fix another NULL-pointer dereference at open should a malicious device
lack an interrupt-in endpoint.

Note that the driver has a broken check for an interrupt-in endpoint
which means that an interrupt URB has never even been submitted.

Fixes: 3f5429746d91 ("USB: Moschip 7840 USB-Serial Driver")
Cc: stable <stable@vger.kernel.org> # v2.6.19: 5c75633ef751
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Johan Hovold <johan@kernel.org>
drivers/usb/serial/mos7840.c