From 3183e7c96e7f66d9f0b215d549912411b146dd77 Mon Sep 17 00:00:00 2001 From: Martin Szulecki Date: Fri, 22 Jan 2010 14:54:40 +0100 Subject: Rename iphone_device_recv/_send functions to use iphone_connection_* domain These communication functions operate on an iphone_connection_t, thus their function name should reflect that. --- src/iphone.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/iphone.c') 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 * * @return IPHONE_E_SUCCESS if ok, otherwise an error code. */ -iphone_error_t iphone_device_send(iphone_connection_t connection, const char *data, uint32_t len, uint32_t *sent_bytes) +iphone_error_t iphone_connection_send(iphone_connection_t connection, const char *data, uint32_t len, uint32_t *sent_bytes) { if (!connection || !data || (connection->ssl_data && !connection->ssl_data->session)) { return IPHONE_E_INVALID_ARG; @@ -350,7 +350,7 @@ static iphone_error_t internal_connection_recv_timeout(iphone_connection_t conne * * @return IPHONE_E_SUCCESS if ok, otherwise an error code. */ -iphone_error_t iphone_device_recv_timeout(iphone_connection_t connection, char *data, uint32_t len, uint32_t *recv_bytes, unsigned int timeout) +iphone_error_t iphone_connection_receive_timeout(iphone_connection_t connection, char *data, uint32_t len, uint32_t *recv_bytes, unsigned int timeout) { if (!connection || (connection->ssl_data && !connection->ssl_data->session)) { return IPHONE_E_INVALID_ARG; @@ -393,7 +393,7 @@ static iphone_error_t internal_connection_recv(iphone_connection_t connection, c /** * Receive data from a device via the given connection. - * This function is like iphone_device_recv_timeout, but with a predefined + * This function is like iphone_connection_receive_timeout, but with a predefined * reasonable timeout. * * @param connection The connection to receive data from. @@ -404,7 +404,7 @@ static iphone_error_t internal_connection_recv(iphone_connection_t connection, c * * @return IPHONE_E_SUCCESS if ok, otherwise an error code. */ -iphone_error_t iphone_device_recv(iphone_connection_t connection, char *data, uint32_t len, uint32_t *recv_bytes) +iphone_error_t iphone_connection_receive(iphone_connection_t connection, char *data, uint32_t len, uint32_t *recv_bytes) { if (!connection || (connection->ssl_data && !connection->ssl_data->session)) { return IPHONE_E_INVALID_ARG; @@ -464,7 +464,7 @@ static ssize_t internal_ssl_read(gnutls_transport_ptr_t transport, char *buffer, /* repeat until we have the full data or an error occurs */ do { if ((res = internal_connection_recv(connection, recv_buffer, this_len, (uint32_t*)&bytes)) != IPHONE_E_SUCCESS) { - debug_info("ERROR: iphone_device_recv returned %d", res); + debug_info("ERROR: iphone_connection_receive returned %d", res); return res; } debug_info("post-read we got %i bytes", bytes); -- cgit v1.1-32-gdbae