Changeset 4172db4a in mainline


Ignore:
Timestamp:
2018-01-25T02:05:57Z (6 years ago)
Author:
Ondřej Hlavatý <aearsis@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
e8277c0
Parents:
92a7b296
git-author:
Ondřej Hlavatý <aearsis@…> (2018-01-24 22:51:14)
git-committer:
Ondřej Hlavatý <aearsis@…> (2018-01-25 02:05:57)
Message:

usb: fix some simple errors clang scan found

Location:
uspace
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/block/usbmast/main.c

    r92a7b296 r4172db4a  
    180180        mdev->luns = calloc(mdev->lun_count, sizeof(ddf_fun_t*));
    181181        if (mdev->luns == NULL) {
    182                 rc = ENOMEM;
    183182                usb_log_error("Failed allocating luns table.");
    184                 goto error;
     183                return ENOMEM;
    185184        }
    186185
  • uspace/drv/bus/usb/usbmid/main.c

    r92a7b296 r4172db4a  
    107107                        usb_log_warning("Failed to turn off child `%s': %s",
    108108                            ddf_fun_get_name(iface->fun), str_error(pret));
    109                         ret = pret;
    110109                }
    111110        }
  • uspace/lib/usbdev/src/devdrv.c

    r92a7b296 r4172db4a  
    555555        if (sess)
    556556                async_hangup(sess);
    557         if (ret != EOK)
     557        if (ret != EOK) {
     558                free(usb_dev);
    558559                return NULL;
     560        }
    559561
    560562        const char* dummy = NULL;
  • uspace/lib/usbhid/src/hidparser.c

    r92a7b296 r4172db4a  
    424424
    425425        if (USB_HID_ITEM_FLAG_CONSTANT(item->item_flags)) {
    426                 ret = item->logical_minimum;
     426                return item->logical_minimum;
    427427        }
    428428
Note: See TracChangeset for help on using the changeset viewer.