| 114 | } |
| 115 | |
| 116 | static hid_device *new_hid_device(void) |
| 117 | { |
| 118 | hid_device *dev = (hid_device *)calloc(1, sizeof(hid_device)); |
| 119 | dev->device_handle = -1; |
| 120 | dev->blocking = 1; |
| 121 | dev->uses_numbered_reports = 0; |
| 122 | dev->is_bluetooth = 0; |
| 123 | |
| 124 | return dev; |
| 125 | } |
| 126 | |
| 127 | |
| 128 | /* The caller must free the returned string with free(). */ |