summaryrefslogtreecommitdiffstats
path: root/src/recovery.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/recovery.h')
-rw-r--r--src/recovery.h20
1 files changed, 18 insertions, 2 deletions
diff --git a/src/recovery.h b/src/recovery.h
index 1953c6a..6cd467c 100644
--- a/src/recovery.h
+++ b/src/recovery.h
@@ -22,12 +22,24 @@
#ifndef IDEVICERESTORE_RECOVERY_H
#define IDEVICERESTORE_RECOVERY_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#include <stdint.h>
#include <plist/plist.h>
+#include <libirecovery.h>
+
+struct recovery_client_t {
+ irecv_client_t client;
+ const char* ipsw;
+ plist_t tss;
+};
int recovery_check_mode();
-int recovery_enter_restore(const char* uuid, const char* ipsw, plist_t tss);
-int recovery_send_signed_component(irecv_client_t client, const char* ipsw, plist_t tss, char* component);
+int recovery_client_new(struct idevicerestore_client_t* client);
+void recovery_client_free(struct idevicerestore_client_t* client);
+int recovery_send_signed_component(struct idevicerestore_client_t* client, const char* ipsw, plist_t tss, char* component) {
irecv_error_t recovery_open_with_timeout(irecv_client_t* client);
int recovery_send_ibec(const char* ipsw, plist_t tss);
int recovery_send_applelogo(const char* ipsw, plist_t tss);
@@ -38,4 +50,8 @@ int recovery_get_ecid(uint64_t* ecid);
int recovery_get_cpid(uint32_t* cpid);
int recovery_get_bdid(uint32_t* bdid);
+#ifdef __cplusplus
+}
+#endif
+
#endif