Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usb/src/recognise.c

    r38648f0 r3b77628  
    359359{
    360360        static size_t device_name_index = 0;
    361         static FIBRIL_MUTEX_INITIALIZE(device_name_index_mutex);
    362 
    363         size_t this_device_name_index;
    364 
    365         fibril_mutex_lock(&device_name_index_mutex);
    366         this_device_name_index = device_name_index;
    367         device_name_index++;
    368         fibril_mutex_unlock(&device_name_index_mutex);
    369 
    370361
    371362        device_t *child = NULL;
     
    383374         * naming etc., something more descriptive could be created.
    384375         */
    385         rc = asprintf(&child_name, "usbdev%02zu", this_device_name_index);
     376        rc = asprintf(&child_name, "usbdev%02zu", device_name_index);
    386377        if (rc < 0) {
    387378                goto failure;
     
    405396        }
    406397       
     398        device_name_index++;
     399
    407400        return EOK;
    408401
Note: See TracChangeset for help on using the changeset viewer.