Hello,

I just tried to use the official master branch of libusbx on Mac OS X
and I get a crash with the listdevs example:

Starting program:
/Users/lroussea/Documents/github/libusbx/examples/.libs/listdevs
Reading symbols for shared libraries
+++++.................................. done
[timestamp] [threadID] facility level [function call] <message>
--------------------------------------------------------------------------------
[ 0.000005] [00000f0b] libusbx: debug [libusb_init] created default context
[ 0.000083] [00000f0b] libusbx: debug [libusb_init] libusbx v1.2.0.10729
Reading symbols for shared libraries . done
[ 0.003879] [00000f0b] libusbx: debug [process_new_device] allocating
new device for location 0x24000000
[ 0.003907] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
device descriptor:
[ 0.003913] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 bDescriptorType:    0x01
[ 0.003919] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 bcdUSB:             0x0200
[ 0.003924] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 bDeviceClass:       0x09
[ 0.003929] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 bDeviceSubClass:    0x00
[ 0.003934] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 bDeviceProtocol:    0x01
[ 0.003939] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 bMaxPacketSize0:    0x40
[ 0.003945] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 idVendor:           0x05ac
[ 0.003950] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 idProduct:          0x8006
[ 0.003955] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 bcdDevice:          0x0200
[ 0.003960] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 iManufacturer:      0x02
[ 0.003966] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 iProduct:           0x01
[ 0.003971] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 iSerialNumber:      0x00
[ 0.003976] [00000f0b] libusbx: debug [darwin_cache_device_descriptor]
 bNumConfigurations: 0x01
[ 0.004006] [00000f0b] libusbx: debug [darwin_check_configuration]
active config: 1, first config: 1

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x0000000000000000
0x00007fff8b70ebf9 in pthread_mutex_lock ()
(gdb) bt
#0  0x00007fff8b70ebf9 in pthread_mutex_lock ()
#1  0x0000000100004124 in libusb_ref_device (dev=0x0) at core.c:955
#2  0x000000010000ddab in process_new_device () at darwin_usb.c:463
#3  0x000000010000e646 in darwin_scan_devices [inlined] () at
/Users/lroussea/Documents/github/libusbx/libusb/os/darwin_usb.c:827
#4  0x000000010000e646 in darwin_init (ctx=0x100106f40) at darwin_usb.c:432
#5  0x000000010000485c in libusb_init (context=0x0) at core.c:1789
#6  0x0000000100000cb6 in main () at listdevs.c:58
(gdb)


Even if the work on Mac OS X is done elsewhere I was hopping the that
the code on https://github.com/libusbx/libusbx would not crash.

I then tried https://github.com/jwrdegoede/libusbx/tree/darwin-integration
but have the same bug (crash).

I also tried https://github.com/hjelmn/libusbx/tree/darwin-integration
but compilation fails with:
make[2]: *** No rule to make target `os/poll_posix.c', needed by
`libusb_1_0_la-poll_posix.lo'.  Stop.
The file os/poll_posix.c is not present in the repository.


Where am I supposed to find the official/supported Mac OS X version of libusbx?

Thanks

--
 Dr. Ludovic Rousseau

------------------------------------------------------------------------------
How ServiceNow helps IT people transform IT departments:
1. A cloud service to automate IT design, transition and operations
2. Dashboards that offer high-level views of enterprise services
3. A single system of record for all IT processes
http://p.sf.net/sfu/servicenow-d2d-j
_______________________________________________
libusbx-devel mailing list
libusbx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libusbx-devel

Reply via email to