From c527fd1f14c27855a37f2e8ac5346ce8d940ced2 Mon Sep 17 00:00:00 2001 From: Tudor Florea Date: Thu, 16 Oct 2014 03:05:19 +0200 Subject: initial commit for Enea Linux 4.0-140929 Migrated from the internal git server on the daisy-enea-point-release branch Signed-off-by: Tudor Florea --- .../usbutils/usbutils/Fix-NULL-pointer-crash.patch | 28 ++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 meta/recipes-bsp/usbutils/usbutils/Fix-NULL-pointer-crash.patch (limited to 'meta/recipes-bsp/usbutils/usbutils/Fix-NULL-pointer-crash.patch') diff --git a/meta/recipes-bsp/usbutils/usbutils/Fix-NULL-pointer-crash.patch b/meta/recipes-bsp/usbutils/usbutils/Fix-NULL-pointer-crash.patch new file mode 100644 index 0000000000..0efdc59fc6 --- /dev/null +++ b/meta/recipes-bsp/usbutils/usbutils/Fix-NULL-pointer-crash.patch @@ -0,0 +1,28 @@ +Fix NULL pointer crash. + +Before use usbbuslist, we should check if it is valid. + +Upstream-Status: Pending +Signed-off-by: Roy.Li +--- + lsusb-t.c | 4 ++++ + 1 files changed, 4 insertions(+), 0 deletions(-) + +diff --git a/lsusb-t.c b/lsusb-t.c +index f604155..583a46a 100644 +--- a/lsusb-t.c ++++ b/lsusb-t.c +@@ -643,6 +643,10 @@ static void sort_busses(void) + /* need to reverse sort bus numbers */ + struct usbbusnode *t, *p, **pp; + int swapped; ++ ++ if (!usbbuslist) ++ return; ++ + do { + p = usbbuslist; + pp = &usbbuslist; +-- +1.7.4.1 + -- cgit v1.2.3-54-g00ecf