Another app made but it crashes while getting systemlog
Closed this issue · 0 comments
I was trying to follow CycriptGUI's code but I got stuck while getting System console
//Delegate here for callback
public delegate void syslog_callback(char c, IntPtr user_data);
//Function here:
[DllImport(LibimobiledeviceDllPath, CallingConvention = CallingConvention.Cdecl)]
static extern syslog_relay_error_t syslog_relay_start_capture(IntPtr client, syslog_callback x, out IntPtr user_data);
//Function Definition here:
private static string tester;
public static void syslog_callback2(char c, IntPtr user_data)
{
tester += c;
//putchar(c);
if (c == '\n')
{
Console.WriteLine(tester);
tester = "";
}
}
//call here
syslog_callback mycallback = new syslog_callback(WindowsFormsApplication1.Form1.syslog_callback2);
syslog_relay_error_t consoleCode2 = syslog_relay_start_capture(client2, mycallback, out test);
I would be really greatful if you could help me out with this, I have been trying to resolve it for sometime now.