Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset d42ba37 in mainline


Ignore:
Timestamp:
2017-11-22T13:54:05Z (4 years ago)
Author:
Ondřej Hlavatý <aearsis@…>
Branches:
lfn, master
Children:
81ee1009
Parents:
820d9bc
Message:

usbhost: usb transfer batch shall be zero-initialized

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usbhost/src/usb_transfer_batch.c

    r820d9bc rd42ba37  
    5555                batch = ep->bus->ops.create_batch(ep->bus, ep);
    5656        else
    57                 batch = malloc(sizeof(usb_transfer_batch_t));
     57                batch = calloc(1, sizeof(usb_transfer_batch_t));
    5858
    5959        return batch;
     
    6464void usb_transfer_batch_init(usb_transfer_batch_t *batch, endpoint_t *ep)
    6565{
    66         memset(batch, 0, sizeof(*batch));
    6766        batch->ep = ep;
    6867}
Note: See TracChangeset for help on using the changeset viewer.