Hi All, Sorry I brought this topic to such a massive audience. But unfortunately upower seems to be still linked with libusb-0.1, and thus bug 427805 and numerous other duplicates are affecting many users. (http://bugs.launchpad.net/bugs/427805)
This happens intermittently and was ignored by me previously until several hours ago I realized there are so many users out there affected by this, mostly Mac users including me, and it looks Mac is vulnerable to this possibly because of the difference in the USB devices' descriptors. Debugged this and came up with a simple fix (a most common error), yet I don't know where to send except as attachment on LP. And we were also talking about deprecating libusb-0.1 in -M, yet this seems to be still useful for Lucid users at this moment. Patch attached. - eric
------------------------------------------------------------ revno: 378 committer: Eric Miao <ycm...@macbook-lucid> branch nick: libusb timestamp: Mon 2010-05-31 16:34:43 +0800 message: Initialized the allocated interface->altsetting to zero This prevents incorrect references to uninitialized fields within interface->altsetting[], which is the case for Bug 427805 - usb_find_devices() crashed with SIGSEGV in free() where an uninitialized '->extra' pointer is being free()'ed in usb_destroy_configuration() called by usb_find_devices(). diff: === modified file 'descriptors.c' --- descriptors.c 2006-02-18 00:28:19 +0000 +++ descriptors.c 2010-05-31 08:34:43 +0000 @@ -176,6 +176,9 @@ return -1; } + memset(interface->altsetting, 0, sizeof(struct usb_interface_descriptor) * + (interface->num_altsetting + 1)); + ifp = interface->altsetting + interface->num_altsetting; interface->num_altsetting++;
-- Ubuntu-devel-discuss mailing list Ubuntu-devel-discuss@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-devel-discuss