CoreTelephony

i would like to know why i have crashes with core telephony, i'm using it only to detect what is the connection is it 3g or 4g, also to know if i'm connected to the internet or no

here is the crash trace

0  libobjc.A.dylib                0x1bb8c21c8 objc_msgSend + 8
1  CoreFoundation                 0x1a6cbb41c -[__NSDictionaryM objectForKeyedSubscript:] + 184
2  CoreTelephony                  0x1a734454c -[CTTelephonyNetworkInfo updateRat:descriptor:] + 144
3  CoreTelephony                  0x1a7344430 -[CTTelephonyNetworkInfo queryRatForDescriptor:] + 164
4  CoreTelephony                  0x1a73431b8 -[CTTelephonyNetworkInfo connectionStateChanged:connection:dataConnectionStatusInfo:] + 72
5  CoreFoundation                 0x1a6de3724 __invoking___ + 148
6  CoreFoundation                 0x1a6cb6d04 -[NSInvocation invoke] + 380
7  CoreFoundation                 0x1a6cb7308 -[NSInvocation invokeWithTarget:] + 80
8  CoreTelephony                  0x1a734d2cc void dispatch::async<-[CoreTelephonyClientMux sink:handleNotification:]::$_2>(dispatch_queue_s*, std::__1::unique_ptr<-[CoreTelephonyClientMux sink:handleNotification:]::$_2, std::__1::default_delete<-[CoreTelephonyClientMux sink:handleNotification:]::$_2> >)::'lambda'(void*)::__invoke(void*) + 44
9  libdispatch.dylib              0x1a69cb81c _dispatch_client_callout + 20
10 libdispatch.dylib              0x1a69d3004 _dispatch_lane_serial_drain + 620
11 libdispatch.dylib              0x1a69d3c00 _dispatch_lane_invoke + 404
12 libdispatch.dylib              0x1a69de4bc _dispatch_workloop_worker_thread + 764
13 libsystem_pthread.dylib        0x1f2a4e7a4 _pthread_wqthread + 276
14 libsystem_pthread.dylib        0x1f2a5574c start_wqthread + 8

With regards your crash, see this thread.

You wrote:

i'm using it only to detect what is the connection is it 3g or 4g, also to know if i'm connected to the internet or no

Can you elaborate more on your goals here? Specifically:

  • Why do you need to distinguish between 3G and 4G?

  • How are you using CT to determine whether you’re connection to the Internet or not?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

CoreTelephony
 
 
Q