From: Christoph S. <hon...@gm...> - 2012-10-02 11:14:41
|
Hi, I guess the code will say more then thousand words, so: long ctx; Usb_Device device; ctx = LibusbJava1.libusb_init(); for (int k = 0; k < 1000000; k++) { System.out.println(" ********************************** " + k); device = LibusbJava1.libusb_get_device_list((Long) ctx); } Thats all i do, and after 1300 calls of the libusb_get_device_list(ctx) command, the Java runtime collapses. Does anyone got this problem with the libusb, or does it have to be a problem with the Java wrapper? Environment: Windows 7 64bit JRE 1.7 libusb1.0 + Javawrapper Windows backend (http://www.libusb.org/wiki/windows_backend) i also tried: long ctx; Usb_Device device; ctx = LibusbJava1.libusb_init(); for (int k = 0; k < 1000000; k++) { System.out.println(" ********************************** " + k); Thread.sleep(500); device = LibusbJava1.libusb_get_device_list((Long) ctx); } but with the same result. Kind Regards chris |