Open cupuyc opened 6 years ago
@cupuyc this should be submitted to the Help Desk via https://red5pro.zendesk.com/hc/en-us/requests/new. Please include the device model and iOS version with your request.
I managed to achieve my goal by next play stream function:
func playStream(streamName: String) {
self.subscribeStream?.stop()
let config = getConfig()
let connection = R5Connection(config: config)
self.subscribeStream = R5Stream(connection: connection)
self.subscribeStream!.delegate = self
self.subscribeStream?.client = self
self.currentView?.attach(subscribeStream)
self.subscribeStream!.play(streamName)
}
Calling it multiple times doesn't crash app for me.
I used Subscribe stream test. Constant stream was published from html5 web app. To reproduce app crash:
iOS 9.3.5 (13G36)
My goal is to be able to play different streams from a single view.
Crash log:
Incident Identifier: F21C1332-6E02-48AC-A2BF-968CAE3086E2 CrashReporter Key: 15aaeb042ed9f7cef1d2974667ab623aee5acb10 Hardware Model: iPad3,3 Process: R5ProTestbed [1433] Path: /private/var/containers/Bundle/Application/E6436131-738C-4B51-9559-1EABE5DD440D/R5ProTestbed.app/R5ProTestbed Identifier: com.infrared5.R5ProTestbed Version: 1 (4.0.0) Code Type: ARM (Native) Parent Process: launchd [1] Date/Time: 2017-12-08 15:20:30.30 +0200 Launch Time: 2017-12-08 15:19:02.02 +0200 OS Version: iOS 9.3.5 (13G36) Report Version: 105 Exception Type: EXC_BAD_ACCESS (SIGSEGV) Exception Subtype: KERN_INVALID_ADDRESS at 0x07074cbd Triggered by Thread: 9 Filtered syslog: None found Global Trace Buffer (reverse chronological seconds): 87.342015 libsystem_trace.dylib 0x00000000247e96fd dyld_image_header_containing_address(0x16d349c9) failed 87.457326 libsystem_trace.dylib 0x00000000247e96fd dyld_image_header_containing_address(0x16d651e9) failed 87.459067 libsystem_trace.dylib 0x00000000247e96fd dyld_image_header_containing_address(0x17b6ea0c) failed Thread 0 name: Dispatch queue: com.apple.main-thread Thread 0: 0 libsystem_kernel.dylib 0x2472effc __semwait_signal + 24 1 libsystem_pthread.dylib 0x247dac5e pthread_join + 362 2 R5ProTestbed 0x000f5bae 0x42000 + 736174 3 R5ProTestbed 0x000ceb66 0x42000 + 576358 4 R5ProTestbed 0x000e626a 0x42000 + 672362 5 R5ProTestbed 0x000e3320 0x42000 + 660256 6 R5ProTestbed 0x00098a20 0x42000 + 354848 7 R5ProTestbed 0x000553e0 0x42000 + 78816 8 R5ProTestbed 0x00055224 0x42000 + 78372 9 R5ProTestbed 0x00055278 0x42000 + 78456 10 UIKit 0x290371a2 -[UIViewController _setViewAppearState:isAnimating:] + 758 11 UIKit 0x290ad20c -[UIViewController __viewWillDisappear:] + 92 12 UIKit 0x290f8618 -[UINavigationController viewWillDisappear:] + 120 13 UIKit 0x290371a2 -[UIViewController _setViewAppearState:isAnimating:] + 758 14 UIKit 0x290ad20c -[UIViewController __viewWillDisappear:] + 92 15 UIKit 0x2961661e -[UISplitViewController setViewControllers:] + 1154 16 UIKit 0x29617466 -[UISplitViewController showDetailViewController:sender:] + 786 17 UIKit 0x293941aa -[UIViewController _showViewController:withAction:sender:] + 94 18 UIKit 0x296483bc __66-[UIStoryboardShowSegueTemplate newDefaultPerformHandlerForSegue:]_block_invoke + 128 19 UIKit 0x29729294 -[UIStoryboardSegueTemplate _performWithDestinationViewController:sender:] + 432 20 UIKit 0x297290c2 -[UIStoryboardSegueTemplate _perform:] + 66 21 UIKit 0x29729334 -[UIStoryboardSegueTemplate perform:] + 132 22 UIKit 0x291530b2 -[UITableView _selectRowAtIndexPath:animated:scrollPosition:notifyDelegate:] + 1022 23 UIKit 0x2920e476 -[UITableView _userSelectRowAtPendingSelectionIndexPath:] + 306 24 UIKit 0x292c74c8 _runAfterCACommitDeferredBlocks + 268 25 UIKit 0x292d37da _cleanUpAfterCAFlushAndRunDeferredBlocks + 90 26 UIKit 0x29011b1c _afterCACommitHandler + 84 27 CoreFoundation 0x24a656c8 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 20 28 CoreFoundation 0x24a639cc __CFRunLoopDoObservers + 280 29 CoreFoundation 0x24a63dfe __CFRunLoopRun + 958 30 CoreFoundation 0x249b3228 CFRunLoopRunSpecific + 520 31 CoreFoundation 0x249b3014 CFRunLoopRunInMode + 108 32 GraphicsServices 0x25fa3ac8 GSEventRunModal + 160 33 UIKit 0x29087188 UIApplicationMain + 144 34 R5ProTestbed 0x0007246c 0x42000 + 197740 35 libdyld.dylib 0x2465b872 start + 2 Thread 1 name: Dispatch queue: com.apple.libdispatch-manager Thread 1: 0 libsystem_kernel.dylib 0x247302f8 kevent_qos + 24 1 libdispatch.dylib 0x24625d60 _dispatch_mgr_invoke + 256 2 libdispatch.dylib 0x24625abe _dispatch_mgr_thread$VARIANT$mp + 38 Thread 2: 0 libsystem_kernel.dylib 0x2472f864 __workq_kernreturn + 8 1 libsystem_pthread.dylib 0x247d5b34 _pthread_wqthread + 1036 2 libsystem_pthread.dylib 0x247d5718 start_wqthread + 8 Thread 3 name: AVAudioSession Notify Thread Thread 3: 0 libsystem_kernel.dylib 0x2471a8d0 mach_msg_trap + 20 1 libsystem_kernel.dylib 0x2471a6d4 mach_msg + 40 2 CoreFoundation 0x24a65ac4 __CFRunLoopServiceMachPort + 136 3 CoreFoundation 0x24a63e4c __CFRunLoopRun + 1036 4 CoreFoundation 0x249b3228 CFRunLoopRunSpecific + 520 5 CoreFoundation 0x249b3014 CFRunLoopRunInMode + 108 6 libAVFAudio.dylib 0x2a372224 GenericRunLoopThread::Entry+ 287268 (void*) + 132 7 libAVFAudio.dylib 0x2a347176 CAPThread::Entry+ 110966 (CAPThread*) + 154 8 libsystem_pthread.dylib 0x247d785a _pthread_body + 138 9 libsystem_pthread.dylib 0x247d77ce _pthread_start + 110 10 libsystem_pthread.dylib 0x247d5724 thread_start + 8 Thread 4: 0 libsystem_kernel.dylib 0x2472e998 __psynch_cvwait + 24 1 libsystem_pthread.dylib 0x247d6dec _pthread_cond_wait + 536 2 libsystem_pthread.dylib 0x247d7c98 pthread_cond_wait + 40 3 R5ProTestbed 0x000f5fc2 0x42000 + 737218 4 R5ProTestbed 0x000e7c66 0x42000 + 679014 5 R5ProTestbed 0x000f5b84 0x42000 + 736132 6 libsystem_pthread.dylib 0x247d785a _pthread_body + 138 7 libsystem_pthread.dylib 0x247d77ce _pthread_start + 110 8 libsystem_pthread.dylib 0x247d5724 thread_start + 8 Thread 5: 0 libsystem_kernel.dylib 0x2472e998 __psynch_cvwait + 24 1 libsystem_pthread.dylib 0x247d6dec _pthread_cond_wait + 536 2 libsystem_pthread.dylib 0x247d7c98 pthread_cond_wait + 40 3 R5ProTestbed 0x000f5fc2 0x42000 + 737218 4 R5ProTestbed 0x000e7c66 0x42000 + 679014 5 R5ProTestbed 0x000f5b84 0x42000 + 736132 6 libsystem_pthread.dylib 0x247d785a _pthread_body + 138 7 libsystem_pthread.dylib 0x247d77ce _pthread_start + 110 8 libsystem_pthread.dylib 0x247d5724 thread_start + 8 Thread 6: 0 libsystem_kernel.dylib 0x2472e998 __psynch_cvwait + 24 1 libsystem_pthread.dylib 0x247d6dec _pthread_cond_wait + 536 2 libsystem_pthread.dylib 0x247d7c98 pthread_cond_wait + 40 3 R5ProTestbed 0x000f5fc2 0x42000 + 737218 4 R5ProTestbed 0x000e7c66 0x42000 + 679014 5 R5ProTestbed 0x000f5b84 0x42000 + 736132 6 libsystem_pthread.dylib 0x247d785a _pthread_body + 138 7 libsystem_pthread.dylib 0x247d77ce _pthread_start + 110 8 libsystem_pthread.dylib 0x247d5724 thread_start + 8 Thread 7: 0 libsystem_kernel.dylib 0x2472e998 __psynch_cvwait + 24 1 libsystem_pthread.dylib 0x247d6dec _pthread_cond_wait + 536 2 libsystem_pthread.dylib 0x247d7c98 pthread_cond_wait + 40 3 R5ProTestbed 0x000f5fc2 0x42000 + 737218 4 R5ProTestbed 0x000e7c66 0x42000 + 679014 5 R5ProTestbed 0x000f5b84 0x42000 + 736132 6 libsystem_pthread.dylib 0x247d785a _pthread_body + 138 7 libsystem_pthread.dylib 0x247d77ce _pthread_start + 110 8 libsystem_pthread.dylib 0x247d5724 thread_start + 8 Thread 8 name: com.red5pro.subscribe_loop Thread 8: 0 libsystem_kernel.dylib 0x2471dde0 kevent + 24 1 R5ProTestbed 0x000f954e 0x42000 + 750926 2 R5ProTestbed 0x000e9ecc 0x42000 + 687820 3 R5ProTestbed 0x000cf674 0x42000 + 579188 4 R5ProTestbed 0x000cf8c4 0x42000 + 579780 5 R5ProTestbed 0x000ede38 0x42000 + 704056 6 R5ProTestbed 0x000e790a 0x42000 + 678154 7 R5ProTestbed 0x000e9716 0x42000 + 685846 8 R5ProTestbed 0x000e99c2 0x42000 + 686530 9 R5ProTestbed 0x000f99c4 0x42000 + 752068 10 R5ProTestbed 0x000e9ecc 0x42000 + 687820 11 R5ProTestbed 0x000ce9a6 0x42000 + 575910 12 R5ProTestbed 0x000cf97c 0x42000 + 579964 13 R5ProTestbed 0x000e5ab6 0x42000 + 670390 14 R5ProTestbed 0x000f5b84 0x42000 + 736132 15 libsystem_pthread.dylib 0x247d785a _pthread_body + 138 16 libsystem_pthread.dylib 0x247d77ce _pthread_start + 110 17 libsystem_pthread.dylib 0x247d5724 thread_start + 8 Thread 9 name: com.red5pro.read_video Thread 9 Crashed: 0 R5ProTestbed 0x001aebf0 0x42000 + 1494000 1 R5ProTestbed 0x001963e8 0x42000 + 1393640 2 R5ProTestbed 0x001a0d1e 0x42000 + 1436958 3 R5ProTestbed 0x001a0880 0x42000 + 1435776 4 R5ProTestbed 0x001a5fa4 0x42000 + 1458084 5 R5ProTestbed 0x001eb384 0x42000 + 1741700 6 R5ProTestbed 0x000e46cc 0x42000 + 665292 7 R5ProTestbed 0x000e4d68 0x42000 + 666984 8 R5ProTestbed 0x000e4eea 0x42000 + 667370 9 R5ProTestbed 0x000c62f8 0x42000 + 541432 10 R5ProTestbed 0x000f5b84 0x42000 + 736132 11 libsystem_pthread.dylib 0x247d785a _pthread_body + 138 12 libsystem_pthread.dylib 0x247d77ce _pthread_start + 110 13 libsystem_pthread.dylib 0x247d5724 thread_start + 8 Thread 10 name: com.red5pro.read_msg Thread 10: 0 libsystem_kernel.dylib 0x2472e998 __psynch_cvwait + 24 1 libsystem_pthread.dylib 0x247d6dec _pthread_cond_wait + 536 2 libsystem_pthread.dylib 0x247d7c98 pthread_cond_wait + 40 3 R5ProTestbed 0x000f5fc2 0x42000 + 737218 4 R5ProTestbed 0x000c5ff4 0x42000 + 540660 5 R5ProTestbed 0x000f5b84 0x42000 + 736132 6 libsystem_pthread.dylib 0x247d785a _pthread_body + 138 7 libsystem_pthread.dylib 0x247d77ce _pthread_start + 110 8 libsystem_pthread.dylib 0x247d5724 thread_start + 8 Thread 11: 0 libsystem_kernel.dylib 0x2472f864 __workq_kernreturn + 8 1 libsystem_pthread.dylib 0x247d5b34 _pthread_wqthread + 1036 2 libsystem_pthread.dylib 0x247d5718 start_wqthread + 8 Thread 9 crashed with ARM Thread State (32-bit): r0: 0x0000000d r1: 0x07074cb0 r2: 0x077352d0 r3: 0x07735050 r4: 0x07074fb0 r5: 0x07735050 r6: 0x002b3218 r7: 0x4072c9d0 r8: 0x00000001 r9: 0x00000000 r10: 0x00000280 r11: 0x07068720 ip: 0x07735050 sp: 0x4072c9b4 lr: 0x077357d0 pc: 0x001aebf0 cpsr: 0x80000030 Binary Images: 0x42000 - 0x2c5fff R5ProTestbed armv7 <7697f5745b4c336ca9b2179b41207076> /var/containers/Bundle/Application/E6436131-738C-4B51-9559-1EABE5DD440D/R5ProTestbed.app/R5ProTestbed 0x62a000 - 0x68dfff SocketIO armv7 <9df1c221e42436ecab9cb1528eaa2c0f> /var/containers/Bundle/Application/E6436131-738C-4B51-9559-1EABE5DD440D/R5ProTestbed.app/Frameworks/SocketIO.framework/SocketIO 0x6f6000 - 0x745fff StarscreamSocketIO armv7 <87f85a07afd33bc08dda2078d4aeee2a> /var/containers/Bundle/Application/E6436131-738C-4B51-9559-1EABE5DD440D/R5ProTestbed.app/Frameworks/StarscreamSocketIO.framework/StarscreamSocketIO 0x79e000 - 0x7b1fff libswiftAVFoundation.dylib armv7