c - Why Does `libusb_bulk_transfer' Return 0? -


i using libusb-1.0. when call:

    int rc = libusb_bulk_transfer(handle_,                                   ep_in_addr,                                   (unsigned char *)buf_,                                   64,                                   &read_,                                   0); 

it returns rc = 0 (no error) , read_ = 0 (zero number of bytes received). have specified infinite timeout (last argument), isn't `libusb_bulk_transfer' supposed block until have data?

sometimes, returns rc = 0 (no error) , read_ == 0 (zero number of bytes received).

a bulk endpoint can send packets zero bytes of data, called 0 packets. not error condition.


Comments

Popular posts from this blog

timeout - Handshake_timeout on RabbitMQ using python and pika from remote vm -

gcc - MinGW's ld cannot perform PE operations on non PE output file -

c# - Search and Add Comment with OpenXML for Word -