summaryrefslogtreecommitdiffstats
path: root/src/iphone.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/iphone.c')
-rw-r--r--src/iphone.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/iphone.c b/src/iphone.c
index 6d95c45..85d136c 100644
--- a/src/iphone.c
+++ b/src/iphone.c
@@ -294,7 +294,7 @@ static iphone_error_t internal_connection_send(iphone_connection_t connection, c
294 * 294 *
295 * @return IPHONE_E_SUCCESS if ok, otherwise an error code. 295 * @return IPHONE_E_SUCCESS if ok, otherwise an error code.
296 */ 296 */
297iphone_error_t iphone_device_send(iphone_connection_t connection, const char *data, uint32_t len, uint32_t *sent_bytes) 297iphone_error_t iphone_connection_send(iphone_connection_t connection, const char *data, uint32_t len, uint32_t *sent_bytes)
298{ 298{
299 if (!connection || !data || (connection->ssl_data && !connection->ssl_data->session)) { 299 if (!connection || !data || (connection->ssl_data && !connection->ssl_data->session)) {
300 return IPHONE_E_INVALID_ARG; 300 return IPHONE_E_INVALID_ARG;
@@ -350,7 +350,7 @@ static iphone_error_t internal_connection_recv_timeout(iphone_connection_t conne
350 * 350 *
351 * @return IPHONE_E_SUCCESS if ok, otherwise an error code. 351 * @return IPHONE_E_SUCCESS if ok, otherwise an error code.
352 */ 352 */
353iphone_error_t iphone_device_recv_timeout(iphone_connection_t connection, char *data, uint32_t len, uint32_t *recv_bytes, unsigned int timeout) 353iphone_error_t iphone_connection_receive_timeout(iphone_connection_t connection, char *data, uint32_t len, uint32_t *recv_bytes, unsigned int timeout)
354{ 354{
355 if (!connection || (connection->ssl_data && !connection->ssl_data->session)) { 355 if (!connection || (connection->ssl_data && !connection->ssl_data->session)) {
356 return IPHONE_E_INVALID_ARG; 356 return IPHONE_E_INVALID_ARG;
@@ -393,7 +393,7 @@ static iphone_error_t internal_connection_recv(iphone_connection_t connection, c
393 393
394/** 394/**
395 * Receive data from a device via the given connection. 395 * Receive data from a device via the given connection.
396 * This function is like iphone_device_recv_timeout, but with a predefined 396 * This function is like iphone_connection_receive_timeout, but with a predefined
397 * reasonable timeout. 397 * reasonable timeout.
398 * 398 *
399 * @param connection The connection to receive data from. 399 * @param connection The connection to receive data from.
@@ -404,7 +404,7 @@ static iphone_error_t internal_connection_recv(iphone_connection_t connection, c
404 * 404 *
405 * @return IPHONE_E_SUCCESS if ok, otherwise an error code. 405 * @return IPHONE_E_SUCCESS if ok, otherwise an error code.
406 */ 406 */
407iphone_error_t iphone_device_recv(iphone_connection_t connection, char *data, uint32_t len, uint32_t *recv_bytes) 407iphone_error_t iphone_connection_receive(iphone_connection_t connection, char *data, uint32_t len, uint32_t *recv_bytes)
408{ 408{
409 if (!connection || (connection->ssl_data && !connection->ssl_data->session)) { 409 if (!connection || (connection->ssl_data && !connection->ssl_data->session)) {
410 return IPHONE_E_INVALID_ARG; 410 return IPHONE_E_INVALID_ARG;
@@ -464,7 +464,7 @@ static ssize_t internal_ssl_read(gnutls_transport_ptr_t transport, char *buffer,
464 /* repeat until we have the full data or an error occurs */ 464 /* repeat until we have the full data or an error occurs */
465 do { 465 do {
466 if ((res = internal_connection_recv(connection, recv_buffer, this_len, (uint32_t*)&bytes)) != IPHONE_E_SUCCESS) { 466 if ((res = internal_connection_recv(connection, recv_buffer, this_len, (uint32_t*)&bytes)) != IPHONE_E_SUCCESS) {
467 debug_info("ERROR: iphone_device_recv returned %d", res); 467 debug_info("ERROR: iphone_connection_receive returned %d", res);
468 return res; 468 return res;
469 } 469 }
470 debug_info("post-read we got %i bytes", bytes); 470 debug_info("post-read we got %i bytes", bytes);