EricssonResearch / EricssonResearch/openwebrtc-examples
NativeDemo ios Crash for iphone6 plus ( 8.1.2)
- Dominant language
- Objective-C
- Stars
- 336
- Forks
- 209
- PR merge metrics
- No merged PRs in 30d
Description
After latest update, NativeDemo start to crash after entering room Id. i think it is related with capturing video.
2016-02-22 12:02:22.480 NativeDemo[2207:315368] **\* Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '**\* -[AVCaptureVideoDevice setActiveVideoMaxFrameDuration:] - the passed activeVideoMaxFrameDuration 4585925428558828667:-1805541344 is not supported by the device. Use -activeFormat.videoSupportedFrameRateRanges to discover valid ranges.'
**\* First throw call stack:
(0x1834f259c 0x193c500e4 0x181d62f10 0x101868df0 0x1018728c8 0x181d62ba0 0x1834f83c0 0x1833f6138 0x18438e5d8 0x1842fdb10 0x10005ffd8 0x100060ce4 0x101868df0 0x1018728c8 0x100060c64 0x100062790 0x1003f853c 0x1003fa1e4 0x1003fc1c4 0x1004786a8 0x1002f3e24 0x1002f7d90 0x194473e80 0x194473ddc 0x194470fb0)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb) bt
NativeDemo was compiled with optimization - stepping may behave oddly; variables may not be available.
- thread #14: tid = 0x4cfe8, 0x00000001943d7270 libsystem_kernel.dylib`__pthread_kill + 8, name = 'video-source:src', queue = 'com.apple.avfoundation.videocapturedevice.state_queue', stop reason = signal SIGABRT
frame #0: 0x00000001943d7270 libsystem_kernel.dylib`**pthread_kill + 8
frame #1: 0x0000000194475228 libsystem_pthread.dylib`pthread_kill + 112
frame #2: 0x000000019434eb18 libsystem_c.dylib`abort + 112
frame #3: 0x0000000193421418 libc++abi.dylib`abort_message + 116
frame #4: 0x0000000193440b8c libc++abi.dylib`default_terminate_handler() + 304
frame #5: 0x0000000193c503c0 libobjc.A.dylib`_objc_terminate() + 128
frame #6: 0x000000019343dbb4 libc++abi.dylib`std::__terminate(void (*)()) + 16
frame #7: 0x000000019343dc24 libc++abi.dylib`std::terminate() + 64
frame #8: 0x0000000193c50318 libobjc.A.dylib`objc_terminate + 12
frame #9: 0x0000000101868e04 libdispatch.dylib`_dispatch_client_callout + 36
frame #10: 0x00000001018728c8 libdispatch.dylib`_dispatch_barrier_sync_f_invoke + 128
frame #11: 0x0000000181d62ba0 AVFoundation`-[AVCaptureFigVideoDevice setActiveVideoMaxFrameDuration:] + 180
frame #12: 0x00000001834f83c0 CoreFoundation`__invoking_** + 144
frame #13: 0x00000001833f6138 CoreFoundation`-[NSInvocation invoke] + 296
frame #14: 0x000000018438e5d8 Foundation`_NSSetValueWithMethod + 276
frame #15: 0x00000001842fdb10 Foundation`-[NSObject(NSKeyValueCoding) setValue:forKey:] + 248
- frame #16: 0x000000010005ffd8 NativeDemo`-[GstAVFVideoSrcImpl setDeviceCaps:](self=0x00000001703838e0, _cmd=, info=0x000000010649fb30) + 908 at avfvideosrc.m:546 [opt]
frame #17: 0x0000000100060ce4 NativeDemo`__30-[GstAVFVideoSrcImpl setCaps:]_block_invoke(.block_descriptor=0x000000010649fb00) + 104 at avfvideosrc.m:712 [opt]
frame #18: 0x0000000101868df0 libdispatch.dylib`_dispatch_client_callout + 16
frame #19: 0x00000001018728c8 libdispatch.dylib`_dispatch_barrier_sync_f_invoke + 128
frame #20: 0x0000000100060c64 NativeDemo`-[GstAVFVideoSrcImpl setCaps:](self=0x00000001703838e0, _cmd=, new_caps=0x00000001051b52c0) + 236 at avfvideosrc.m:696 [opt]
frame #21: 0x0000000100062790 NativeDemo`gst_avf_video_src_set_caps(basesrc=0x0000000101c50ef0, caps=) + 80 at avfvideosrc.m:1341 [opt]
frame #22: 0x00000001003f853c NativeDemo`gst_base_src_set_caps(src=0x0000000101c50ef0, caps=0x00000001051b52c0) + 116 at gstbasesrc.c:922 [opt]
frame #23: 0x00000001003fa1e4 NativeDemo`gst_base_src_default_negotiate(basesrc=0x0000000101c50ef0) + 416 at gstbasesrc.c:3232 [opt]
frame #24: 0x00000001003fc1c4 NativeDemo`gst_base_src_loop [inlined] gst_base_src_negotiate + 40 at gstbasesrc.c:3272 [opt]
frame #25: 0x00000001003fc19c NativeDemo`gst_base_src_loop(pad=0x0000000101c56b20) + 156 at gstbasesrc.c:2698 [opt]
frame #26: 0x00000001004786a8 NativeDemo`gst_task_func(task=0x000000010522c060) + 360 at gsttask.c:331 [opt]
frame #27: 0x00000001002f3e24 NativeDemo`g_thread_pool_thread_proxy(data=) + 204 at gthreadpool.c:307 [opt]
frame #28: 0x00000001002f7d90 NativeDemo`g_thread_proxy(data=0x00000001051b4230) + 92 at gthread.c:778 [opt]
frame #29: 0x0000000194473e80 libsystem_pthread.dylib`_pthread_body + 164
frame #30: 0x0000000194473ddc libsystem_pthread.dylib`_pthread_start + 160
(lldb)
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the crash in NativeDemo by entering a room ID on an iPhone 6 Plus running iOS 8.1.2, then inspect avfvideosrc.m at lines 546, 696, 712, and 1341. Start with the setDeviceCaps: call shown in the stack trace and compare the requested frame duration with the device's supported ranges. Done means video capture no longer aborts during caps negotiation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ios, objective-c
- Domain
- audio-video-rtc, mobile-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 35/100