summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorGravatar Geoffrey Kruse2021-03-07 10:03:55 -0800
committerGravatar Nikias Bassen2022-05-05 18:54:55 +0200
commitaee82afabfcf763618f58c95f9613b40dcf334b0 (patch)
tree16508d80b64f52d915e5bf122a0c4cf6d0aca85f /include
parenta070a2e0b8774132a2c90822ba22580c4d1842da (diff)
downloadlibimobiledevice-aee82afabfcf763618f58c95f9613b40dcf334b0.tar.gz
libimobiledevice-aee82afabfcf763618f58c95f9613b40dcf334b0.tar.bz2
idevicebtlogger: Cleanup warnings, todos and magic numbers
Diffstat (limited to 'include')
-rw-r--r--include/libimobiledevice/bt_packet_logger.h20
1 files changed, 7 insertions, 13 deletions
diff --git a/include/libimobiledevice/bt_packet_logger.h b/include/libimobiledevice/bt_packet_logger.h
index 697e879..8916219 100644
--- a/include/libimobiledevice/bt_packet_logger.h
+++ b/include/libimobiledevice/bt_packet_logger.h
@@ -31,6 +31,7 @@ extern "C" {
#include <libimobiledevice/lockdown.h>
#define BT_PACKETLOGGER_SERVICE_NAME "com.apple.bluetooth.BTPacketLogger"
+#define BT_MAX_PACKET_SIZE 65535
/** Error Codes */
typedef enum {
@@ -43,6 +44,12 @@ typedef enum {
BT_PACKET_LOGGER_E_UNKNOWN_ERROR = -256
} bt_packet_logger_error_t;
+typedef struct {
+ uint32_t length;
+ uint32_t ts_secs;
+ uint32_t ts_usecs;
+} bt_packet_logger_header_t;
+
typedef struct bt_packet_logger_client_private bt_packet_logger_client_private;
typedef bt_packet_logger_client_private *bt_packet_logger_client_t; /**< The client handle. */
@@ -141,19 +148,6 @@ bt_packet_logger_error_t bt_packet_logger_stop_capture(bt_packet_logger_client_t
*/
bt_packet_logger_error_t bt_packet_logger_receive_with_timeout(bt_packet_logger_client_t client, char *data, uint32_t size, uint32_t *received, unsigned int timeout);
-/**
- * Receives data from the service.
- *
- * @param client The bt_packet_logger client
- * @param data Buffer that will be filled with the data received
- * @param size Number of bytes to receive
- * @param received Number of bytes received (can be NULL to ignore)
- * @param timeout Maximum time in milliseconds to wait for data.
- *
- * @return BT_PACKET_LOGGER_E_SUCCESS on success,
- * BT_PACKET_LOGGER_E_INVALID_ARG when client or plist is NULL
- */
-bt_packet_logger_error_t bt_packet_logger_receive(bt_packet_logger_client_t client, char *data, uint32_t size, uint32_t *received);
#ifdef __cplusplus
}