1
0
mirror of https://github.com/danog/libtgvoip.git synced 2024-12-02 09:37:52 +01:00
libtgvoip/os/darwin/TGLogWrapper.m

14 lines
389 B
Mathematica
Raw Permalink Normal View History

2017-02-02 17:24:40 +01:00
#import <Foundation/Foundation.h>
2018-01-24 15:56:42 +01:00
void (*TGVoipLoggingFunction)(NSString *) = NULL;
2017-03-30 16:06:59 +02:00
void __tgvoip_call_tglog(const char* format, ...){
2018-05-15 20:23:46 +02:00
va_list args;
va_start(args, format);
NSString *string = [[NSString alloc] initWithFormat:[[NSString alloc]initWithUTF8String:format] arguments:args];
va_end(args);
if (TGVoipLoggingFunction) {
TGVoipLoggingFunction(string);
2018-01-24 15:56:42 +01:00
}
2017-03-30 16:06:59 +02:00
}