Log idevice to the documents directory

This commit is contained in:
Jackson Coxson 2025-03-30 16:17:12 -06:00
parent 1ae3326a5d
commit 0bc64bcc72
No known key found for this signature in database
GPG key ID: 5EAEF578E866A64B
3 changed files with 4 additions and 1 deletions

View file

@ -51,6 +51,10 @@ struct HeartbeatApp: App {
}
return
}
var log_path = URL.documentsDirectory.appendingPathComponent("idevice_log.txt").path.utf8CString
log_path.withUnsafeMutableBufferPointer { buffer in
idevice_init_logger(Debug, Debug, buffer.baseAddress)
}
startProxy() { result, error in
if result {
checkVPNConnection() { result, vpn_error in

View file

@ -14,7 +14,6 @@
void startHeartbeat(IdevicePairingFile* pairing_file, TcpProviderHandle** provider, int* heartbeatSessionId, HeartbeatCompletionHandlerC completion, LogFuncC logger) {
int currentSessionId = *heartbeatSessionId;
logger("DEBUG: Initializing logger...");
idevice_init_logger(Debug, Disabled, NULL);
struct sockaddr_in addr;
memset(&addr, 0, sizeof(addr));

Binary file not shown.