libimobiledevice  1.3.0
API Documentation - Return to Homepage

◆ idevice_connection_receive_timeout()

idevice_error_t idevice_connection_receive_timeout ( idevice_connection_t  connection,
char *  data,
uint32_t  len,
uint32_t *  recv_bytes,
unsigned int  timeout 
)

Receive data from a device via the given connection.

This function will return after the given timeout even if no data has been received.

Parameters
connectionThe connection to receive data from.
dataBuffer that will be filled with the received data. This buffer has to be large enough to hold len bytes.
lenBuffer size or number of bytes to receive.
recv_bytesNumber of bytes actually received.
timeoutTimeout in milliseconds after which this function should return even if no data has been received.
Returns
IDEVICE_E_SUCCESS if ok, otherwise an error code.