Commit 5c076d066a6247353706abcbdf7f10fb71c10deb

Authored by achemin1
1 parent efd291fb

rm le warning de gcc sur l'assignation d'un const, avec des cast

Showing 1 changed file with 4 additions and 4 deletions   Show diff stats
src/libusb_wrapper.c
... ... @@ -259,15 +259,15 @@ void getOurInterfaces(libusb_device *device,
259 259 //itération des interfaces
260 260 for (int indexInterface = 0; indexInterface < config->bNumInterfaces; indexInterface++) {
261 261  
262   - struct libusb_interface * interface = &config->interface[indexInterface];
  262 + const struct libusb_interface * interface = &config->interface[indexInterface];
263 263  
264 264 //todo use le descriptor pour avoir bInterfaceNumber?
265 265 if(indexInterface==0){
266   - *int_hidjoy = interface;
  266 + *int_hidjoy = (struct libusb_interface *)interface;
267 267 }else if(indexInterface==1){
268   - *int_leds = interface;
  268 + *int_leds = (struct libusb_interface *)interface;
269 269 }else if(indexInterface==2){
270   - *int_vibrators = interface;
  270 + *int_vibrators = (struct libusb_interface *)interface;
271 271 }
272 272  
273 273 //#define pour les indices correspondants aux interfaces
... ...