Crash in MPAVRoutingController introduced in iOS 11.2

Originator:javier.api
Number:rdar://36794914 Date Originated:23-Jan-2018 02:46 PM
Status:Open Resolved:
Product:iOS + SDK Product Version:11.2
Classification:Crash/Hang/Data Loss Reproducible:Sometimes
 
Summary:
We started seeing hundreds of crashes in MPAVRoutingController that only seem to affect 11.2.x.

Steps to Reproduce:
Unclear

Expected Results:
Our app doesn’t crash with `MPAVRoutingController` in the stack trace.

Actual Results:
Our app crashes in `MPAVRoutingController`

Version:
11.2

Notes:
Crash info:

EXC_BAD_ACCESS KERN_INVALID_ADDRESS 0x0000000d4e23beb8

Crashed: com.apple.main-thread
0  libobjc.A.dylib                0x1823b0430 objc_msgSend + 16
1  CoreFoundation                 0x18306d15c +[NSSet setWithArray:] + 48
2  MediaPlayer                    0x193bb7238 __62-[MPAVRoutingController _pickableRoutesDidChangeNotification:]_block_invoke + 92
3  MediaPlayer                    0x193bb4bc0 __67-[MPAVRoutingController fetchAvailableRoutesWithCompletionHandler:]_block_invoke_4 + 168
4  libdispatch.dylib              0x182ad2a54 _dispatch_call_block_and_release + 24
5  libdispatch.dylib              0x182ad2a14 _dispatch_client_callout + 16
6  libdispatch.dylib              0x182adf698 _dispatch_main_queue_callback_4CF$VARIANT$mp + 1016
7  CoreFoundation                 0x1830fe544 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 12
8  CoreFoundation                 0x1830fc120 __CFRunLoopRun + 2012
9  CoreFoundation                 0x18301be58 CFRunLoopRunSpecific + 436
10 GraphicsServices               0x184ec8f84 GSEventRunModal + 100
11 UIKit                          0x18c69b67c UIApplicationMain + 236
12 Twitch                         0x100f5fe34 main (main.m:22)

com.apple.coremedia.routingcontext.xpc.notifications
0  libsystem_kernel.dylib         0x182c47568 mach_msg_trap + 8
1  libsystem_kernel.dylib         0x182c473e0 mach_msg + 72
2  libdispatch.dylib              0x182aec068 _dispatch_mach_msg_send + 752
3  libdispatch.dylib              0x182aeb6b8 _dispatch_mach_send_drain + 480
4  libdispatch.dylib              0x182ae8448 _dispatch_mach_send_msg + 456
5  libdispatch.dylib              0x182ae8728 _dispatch_mach_send_and_wait_for_reply + 284
6  libdispatch.dylib              0x182ae8d3c dispatch_mach_send_with_result_and_wait_for_reply$VARIANT$mp + 56
7  libxpc.dylib                   0x182db7d7c xpc_connection_send_message_with_reply_sync + 196
8  CoreMedia                      0x186397f78 FigXPCRemoteClientSendSyncMessageCreatingReply + 36
9  CoreMedia                      0x186315ba4 routingContextRemoteXPC_CopySelectedRouteDescriptors + 92
10 AVFoundation                   0x188b54b18 -[AVFigRouteDescriptorFigRoutingContextOutputDeviceTranslator outputDevicesFromRoutingContext:] + 88
11 MediaRemote                    0x18e8453e4 -[MRAVOutputContext _outputDevicesDidChangeNotification:] + 236
12 CoreFoundation                 0x1830e833c __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 20
13 CoreFoundation                 0x1830e78dc _CFXRegistrationPost + 420
14 CoreFoundation                 0x1830e7640 ___CFXNotificationPost_block_invoke + 60
15 CoreFoundation                 0x183165024 -[_CFXNotificationRegistrar find:object:observer:enumerator:] + 1408
16 CoreFoundation                 0x18301df60 _CFXNotificationPost + 380
17 Foundation                     0x183a4b348 -[NSNotificationCenter postNotificationName:object:userInfo:] + 68
18 AVFoundation                   0x188b02be8 AVCMNotificationDispatcherCallback + 200
19 CoreFoundation                 0x1830e833c __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 20
20 CoreFoundation                 0x1830e78dc _CFXRegistrationPost + 420
21 CoreFoundation                 0x1830e7640 ___CFXNotificationPost_block_invoke + 60
22 CoreFoundation                 0x183165024 -[_CFXNotificationRegistrar find:object:observer:enumerator:] + 1408
23 CoreFoundation                 0x18301df60 _CFXNotificationPost + 380
24 CoreFoundation                 0x18304137c CFNotificationCenterPostNotification + 132
25 CoreMedia                      0x1862927a0 CMNotificationCenterPostNotification + 124
26 CoreMedia                      0x18639b0ec __figXPC_HandleNotificationMessage_block_invoke + 164
27 libdispatch.dylib              0x182ad2a54 _dispatch_call_block_and_release + 24
28 libdispatch.dylib              0x182ad2a14 _dispatch_client_callout + 16
29 libdispatch.dylib              0x182adc96c _dispatch_queue_serial_drain$VARIANT$mp + 528
30 libdispatch.dylib              0x182add2fc _dispatch_queue_invoke$VARIANT$mp + 340
31 libdispatch.dylib              0x182addd20 _dispatch_root_queue_drain_deferred_wlh$VARIANT$mp + 404
32 libdispatch.dylib              0x182ae603c _dispatch_workloop_worker_thread$VARIANT$mp + 644
33 libsystem_pthread.dylib        0x182d7af1c _pthread_wqthread + 932
34 libsystem_pthread.dylib        0x182d7ab6c start_wqthread + 4

Comments

Hi Javier, I've been having a similar issue on iOS 11.2.1. Is the Apple Ticket number the same as this Radar ticket - 36794914? Do you have an update for the Apple Ticket that this Radar Ticket relates to? If yes, can you please update this Radar ticket with information/status of the actual Apple ticket?

Thanks & Regards, Gaurang Rathod.

By gaurang.rathod at Feb. 28, 2018, 1:20 p.m. (reply...)

Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!