Ignore:
Timestamp:
2011-12-05T20:34:52Z (12 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
f167f55
Parents:
c3887ad
Message:

usb: Use macros from macros.h header.

File:
1 edited

Legend:

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

    rc3887ad r3f162ab  
    3434#include <errno.h>
    3535#include <str_error.h>
     36#include <macros.h>
    3637
    3738#include <usb/usb.h>
     
    146147                /* We care about the data and there are some to copy */
    147148                if (data) {
    148                         const size_t min_size = size < instance->buffer_size
    149                             ? size : instance->buffer_size;
    150                         memcpy(instance->buffer, data, min_size);
     149                        const size_t minsize = min(size, instance->buffer_size);
     150                        memcpy(instance->buffer, data, minsize);
    151151                }
    152152                instance->callback_in(instance->fun, instance->error,
Note: See TracChangeset for help on using the changeset viewer.