Skip to content

macosx: Fix NSRangeException

Fix for this stack trace: pastebin

[000000010c4a14c0] upnp renderer discovery warning: search timeout
2025-07-04 16:10:04.361863+0300 vlc-osx-static[2897:212830] *** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArrayM replaceObjectAtIndex:withObject:]: index 16 beyond bounds [0 .. 15]'
*** First throw call stack:
(
        0   CoreFoundation                      0x000000019e306ca0 __exceptionPreprocess + 176
        1   libobjc.A.dylib                     0x000000019ddcab90 objc_exception_throw + 88
        2   CoreFoundation                      0x000000019e23fa30 -[__NSArrayM copy] + 0
        3   libmacosx_plugin.dylib              0x0000000104d173b8 __46-[VLCLibraryModel handleMediaItemUpdateEvent:]_block_invoke + 240
        4   libmacosx_plugin.dylib              0x0000000104d16f64 __58-[VLCLibraryModel performActionOnMediaItemInCache:action:]_block_invoke.118 + 68
        5   libdispatch.dylib                   0x000000019e00c85c _dispatch_client_callout + 16
        6   libdispatch.dylib                   0x000000019e002880 _dispatch_async_and_wait_invoke + 84
        7   libdispatch.dylib                   0x000000019e00c85c _dispatch_client_callout + 16
        8   libdispatch.dylib 
*** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArrayM replaceObjectAtIndex:withObject:]: index 16 beyond bounds [0 .. 15]'
*** First throw call stack:
(
        0   CoreFoundation                      0x000000019e306ca0 __exceptionPreprocess + 176
        1   libobjc.A.dylib                     0x000000019ddcab90 objc_exception_throw + 88
        2   CoreFoundation                      0x000000019e23fa30 -[__NSArrayM copy] + 0
        3   libmacosx_plugin.dylib              0x0000000104d173b8 __46-[VLCLibraryModel handleMediaItemUpdateEvent:]_block_invoke + 240
        4   libmacosx_plugin.dylib              0x0000000104d16f64 __58-[VLCLibraryModel performActionOnMediaItemInCache:action:]_block_invoke.118 + 68
        5   libdispatch.dylib                   0x000000019e00c85c _dispatch_client_callout + 16
        6   libdispatch.dylib                   0x000000019e002880 _dispatch_async_and_wait_invoke + 84
        7   libdispatch.dylib                   0x000000019e00c85c _dispatch_client_callout + 16
        8   libdispatch.dylib                   0x000000019e029b58 _dispatch_main_queue_drain.cold.5 + 812
        9   libdispatch.dylib                   0x000000019e001db0 _dispatch_main_queue_drain + 180
        10  libdispatch.dylib                   0x000000019e001cec _dispatch_main_queue_callback_4CF + 44
        11  CoreFoundation                      0x000000019e2d3da4 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16
        12  CoreFoundation                      0x000000019e294a9c __CFRunLoopRun + 1980
        13  CoreFoundation                      0x000000019e293c58 CFRunLoopRunSpecific + 572
        14  HIToolbox                           0x00000001a9d2827c RunCurrentEventLoopInMode + 324
        15  HIToolbox                           0x00000001a9d2b4e8 ReceiveNextEventCommon + 676
        16  HIToolbox                           0x00000001a9eb6484 _BlockUntilNextEventMatchingListInModeWithFilter + 76
        17  AppKit                              0x00000001a21bbab4 _DPSNextEvent + 684
        18  AppKit                              0x00000001a2b5a5b0 -[NSApplication(NSEventRouting) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 688
        19  AppKit                              0x00000001a21aec64 -[NSApplication run] + 480
        20  libmacosx_plugin.dylib              0x0000000104d816f0 __OpenIntf_block_invoke + 868
        21  CoreFoundation                      0x000000019e295874 __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 28
        22  CoreFoundation                      0x000000019e295784 __CFRunLoopDoBlocks + 352
        23  CoreFoundation                      0x000000019e294c30 __CFRunLoopRun + 2384
        24  CoreFoundation                      0x000000019e293c58 CFRunLoopRunSpecific + 572
        25  CoreFoundation                      0x000000019e30d714 CFRunLoopRun + 64
        26  vlc-osx-static                      0x0000000100002d30 main + 1824
        27  dyld                                0x000000019de0ab98 start + 6076
)
2025-07-04 16:10:04.362387+0300 vlc-osx-static[2897:212830] [General] An uncaught exception was raised
2025-07-04 16:10:04.362445+0300 vlc-osx-static[2897:212830] [General] *** -[__NSArrayM replaceObjectAtIndex:withObject:]: index 16 beyond bounds [0 .. 15]
2025-07-04 16:10:04.362560+0300 vlc-osx-static[2897:212830] [General] (
        0   CoreFoundation                      0x000000019e306ca0 __exceptionPreprocess + 176
        1   libobjc.A.dylib                     0x000000019ddcab90 objc_exception_throw + 88
        2   CoreFoundation                      0x000000019e23fa30 -[__NSArrayM copy] + 0
        3   libmacosx_plugin.dylib              0x0000000104d173b8 __46-[VLCLibraryModel handleMediaItemUpdateEvent:]_block_invoke + 240
        4   libmacosx_plugin.dylib              0x0000000104d16f64 __58-[VLCLibraryModel performActionOnMediaItemInCache:action:]_block_invoke.118 + 68
        5   libdispatch.dylib                   0x000000019e00c85c _dispatch_client_callout + 16
        6   libdispatch.dylib                   0x000000019e002880 _dispatch_async_and_wait_invoke + 84
        7   libdispatch.dylib                   0x000000019e00c85c _dispatch_client_callout + 16
        8   libdispatch.dylib                   0x000000019e029b58 _dispatch_main_queue_drain.cold.5 + 812
        9   libdispatch.dylib                   0x000000019e001db0 _dispatch_main_queue_drain + 180
        10  libdispatch.dylib                   0x000000019e001cec _dispatch_main_queue_callback_4CF + 44
        11  CoreFoundation                      0x000000019e2d3da4 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16
        12  CoreFoundation                      0x000000019e294a9c __CFRunLoopRun + 1980
        13  CoreFoundation                      0x000000019e293c58 CFRunLoopRunSpecific + 572
        14  HIToolbox                           0x00000001a9d2827c RunCurrentEventLoopInMode + 324
        15  HIToolbox                           0x00000001a9d2b4e8 ReceiveNextEventCommon + 676
        16  HIToolbox                           0x00000001a9eb6484 _BlockUntilNextEventMatchingListInModeWithFilter + 76
        17  AppKit                              0x00000001a21bbab4 _DPSNextEvent + 684
        18  AppKit                              0x00000001a2b5a5b0 -[NSApplication(NSEventRouting) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 688
        19  AppKit                              0x00000001a21aec64 -[NSApplication run] + 480
        20  libmacosx_plugin.dylib              0x0000000104d816f0 __OpenIntf_block_invoke + 868
        21  CoreFoundation                      0x000000019e295874 __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 28
        22  CoreFoundation                      0x000000019e295784 __CFRunLoopDoBlocks + 352
        23  CoreFoundation                      0x000000019e294c30 __CFRunLoopRun + 2384
        24  CoreFoundation                      0x000000019e293c58 CFRunLoopRunSpecific + 572
        25  CoreFoundation                      0x000000019e30d714 CFRunLoopRun + 64
        26  vlc-osx-static                      0x0000000100002d30 main + 1824
        27  dyld                                0x000000019de0ab98 start + 6076
)
2025-07-04 16:10:04.364665+0300 vlc-osx-static[2897:212830] [HIExceptions] FAULT: NSRangeException: *** -[__NSArrayM replaceObjectAtIndex:withObject:]: index 16 beyond bounds [0 .. 15]; (user info absent)
libc++abi: terminating due to uncaught exception of type NSException
Process 2897 stopped
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGABRT
    frame #0: 0x000000019e171388 libsystem_kernel.dylib`__pthread_kill + 8
libsystem_kernel.dylib`__pthread_kill:
->  0x19e171388 <+8>:  b.lo   0x19e1713a8    ; <+40>
    0x19e17138c <+12>: pacibsp 
    0x19e171390 <+16>: stp    x29, x30, [sp, #-0x10]!
    0x19e171394 <+20>: mov    x29, sp
Target 0: (vlc-osx-static) stopped.
(lldb) bt
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGABRT
  * frame #0: 0x000000019e171388 libsystem_kernel.dylib`__pthread_kill + 8
    frame #1: 0x000000019e1aa88c libsystem_pthread.dylib`pthread_kill + 296
    frame #2: 0x000000019e0b3c60 libsystem_c.dylib`abort + 124
    frame #3: 0x000000019e16039c libc++abi.dylib`abort_message + 132
    frame #4: 0x000000019e14ed0c libc++abi.dylib`demangling_terminate_handler() + 344
    frame #5: 0x000000019ddd4dd4 libobjc.A.dylib`_objc_terminate() + 156
    frame #6: 0x000000019e15f6b0 libc++abi.dylib`std::__terminate(void (*)()) + 16
    frame #7: 0x000000019e162c48 libc++abi.dylib`__cxxabiv1::failed_throw(__cxxabiv1::__cxa_exception*) + 88
    frame #8: 0x000000019e162bf0 libc++abi.dylib`__cxa_throw + 92
    frame #9: 0x000000019ddcacf8 libobjc.A.dylib`objc_exception_throw + 448
    frame #10: 0x000000019e23fa30 CoreFoundation`-[__NSArrayM replaceObjectAtIndex:withObject:] + 1020
    frame #11: 0x0000000104d173b8 libmacosx_plugin.dylib`__46-[VLCLibraryModel handleMediaItemUpdateEvent:]_block_invoke(.block_descriptor=0x000000010eec1ad0, cachedMediaArray=@"16 elements", cachedMediaIndex=1, recentMediaArray=@"17 elements", recentMediaIndex=16) at VLCLibraryModel.m:968:13
    frame #12: 0x0000000104d16f64 libmacosx_plugin.dylib`__58-[VLCLibraryModel performActionOnMediaItemInCache:action:]_block_invoke.118(.block_descriptor=0x000000017169e740) at VLCLibraryModel.m:934:17
    frame #13: 0x000000019e00c85c libdispatch.dylib`_dispatch_client_callout + 16
    frame #14: 0x000000019e002880 libdispatch.dylib`_dispatch_async_and_wait_invoke + 84
    frame #15: 0x000000019e00c85c libdispatch.dylib`_dispatch_client_callout + 16
    frame #16: 0x000000019e029b58 libdispatch.dylib`_dispatch_main_queue_drain.cold.5 + 812
    frame #17: 0x000000019e001db0 libdispatch.dylib`_dispatch_main_queue_drain + 180
    frame #18: 0x000000019e001cec libdispatch.dylib`_dispatch_main_queue_callback_4CF + 44
    frame #19: 0x000000019e2d3da4 CoreFoundation`__CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16
    frame #20: 0x000000019e294a9c CoreFoundation`__CFRunLoopRun + 1980
    frame #21: 0x000000019e293c58 CoreFoundation`CFRunLoopRunSpecific + 572
    frame #22: 0x00000001a9d2827c HIToolbox`RunCurrentEventLoopInMode + 324
    frame #23: 0x00000001a9d2b4e8 HIToolbox`ReceiveNextEventCommon + 676
    frame #24: 0x00000001a9eb6484 HIToolbox`_BlockUntilNextEventMatchingListInModeWithFilter + 76
    frame #25: 0x00000001a21bbab4 AppKit`_DPSNextEvent + 684
    frame #26: 0x00000001a2b5a5b0 AppKit`-[NSApplication(NSEventRouting) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 688
    frame #27: 0x00000001a21aec64 AppKit`-[NSApplication run] + 480
    frame #28: 0x0000000104d816f0 libmacosx_plugin.dylib`__OpenIntf_block_invoke(.block_descriptor=0x000000015295e2f0) at VLCMain.m:195:13
    frame #29: 0x000000019e295874 CoreFoundation`__CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 28
    frame #30: 0x000000019e295784 CoreFoundation`__CFRunLoopDoBlocks + 352
    frame #31: 0x000000019e294c30 CoreFoundation`__CFRunLoopRun + 2384
    frame #32: 0x000000019e293c58 CoreFoundation`CFRunLoopRunSpecific + 572
    frame #33: 0x000000019e30d714 CoreFoundation`CFRunLoopRun + 64
    frame #34: 0x0000000100002d30 vlc-osx-static`main(i_argc=1, ppsz_argv=0x000000016fdff268) at darwinvlc.m:313:9
    frame #35: 0x000000019de0ab98 dyld`start + 6076
Edited by Bob Moriasi

Merge request reports

Loading