Commit e87ae64
committed
software/usb/device: endpoint should keep reference to the usb device
without reference to the device, and depending on the invocation
the usb device may be collected by the garbage collector while
the usb endpoint is still in use.
this causes the following error which is difficult to trace:
python: core.c:1278: libusb_ref_device: Assertion `refcnt >= 2' failed.
now the endpoint keeps a reference to the device preventing it to be freed1 parent ba52bef commit e87ae64
1 file changed
+5
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
| 11 | + | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
| 18 | + | |
17 | 19 | | |
18 | 20 | | |
19 | 21 | | |
| |||
98 | 100 | | |
99 | 101 | | |
100 | 102 | | |
101 | | - | |
| 103 | + | |
| 104 | + | |
102 | 105 | | |
103 | 106 | | |
104 | 107 | | |
| |||
0 commit comments