2.2.x build on macOS High Sierra crashes
How to reproduce: Take an VLC 2.2.6 or 2.2.7 build on high Sierra and try to open an invalid MRL a couple of times, e.g.:
lldb -- VLC.app/Contents/MacOS/VLC -vv /Users/dfuhrmann/Documents/invalid
Assertion failed: (NSViewIsCurrentlyBuildingLayerTreeForDisplay() != currentlyBuildingLayerTree), function NSViewSetCurrentlyBuildingLayerTreeForDisplay, file /BuildRoot/Library/Caches/com.apple.xbs/Sources/AppKit/AppKit-1561/AppKit.subproj/NSView.m, line 14497.
Process 28102 stopped
* thread [#15](https://code.videolan.org/videolan/vlc/-/issues/15), stop reason = EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0)
frame [#0](https://code.videolan.org/videolan/vlc/-/issues/0): 0x00007fff7bd5f3ca libsystem_c.dylib`__abort + 177
libsystem_c.dylib`__abort:
-> 0x7fff7bd5f3ca <+177>: ud2
libsystem_c.dylib`abort_report_np:
0x7fff7bd5f3cc <+0>: pushq %rbp
0x7fff7bd5f3cd <+1>: movq %rsp, %rbp
0x7fff7bd5f3d0 <+4>: pushq %r14
Target 0: (VLC) stopped.
(lldb) bt
* thread [#15](https://code.videolan.org/videolan/vlc/-/issues/15), stop reason = EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0)
* frame [#0](https://code.videolan.org/videolan/vlc/-/issues/0): 0x00007fff7bd5f3ca libsystem_c.dylib`__abort + 177
frame [#1](https://code.videolan.org/videolan/vlc/-/issues/1): 0x00007fff7bd5f319 libsystem_c.dylib`abort + 142
frame [#2](https://code.videolan.org/videolan/vlc/-/issues/2): 0x00007fff7bd27360 libsystem_c.dylib`__assert_rtn + 320
frame [#3](https://code.videolan.org/videolan/vlc/-/issues/3): 0x00007fff525ae84a AppKit`NSViewSetCurrentlyBuildingLayerTreeForDisplay + 255
frame [#4](https://code.videolan.org/videolan/vlc/-/issues/4): 0x00007fff525ae6bd AppKit`NSViewBuildLayerTreeForDisplay + 50
frame [#5](https://code.videolan.org/videolan/vlc/-/issues/5): 0x00007fff51e3969d AppKit`-[NSWindow displayIfNeeded] + 264
frame [#6](https://code.videolan.org/videolan/vlc/-/issues/6): 0x00007fff525d896b AppKit`___NSWindowGetDisplayCycleObserver_block_invoke.5897 + 308
frame [#7](https://code.videolan.org/videolan/vlc/-/issues/7): 0x00007fff51e391e2 AppKit`__37+[NSDisplayCycle currentDisplayCycle]_block_invoke + 695
frame [#8](https://code.videolan.org/videolan/vlc/-/issues/8): 0x00007fff5f7c555f QuartzCore`CA::Transaction::run_commit_handlers(CATransactionPhase) + 49
frame [#9](https://code.videolan.org/videolan/vlc/-/issues/9): 0x00007fff5f7c4121 QuartzCore`CA::Transaction::commit() + 171
frame [#10](https://code.videolan.org/videolan/vlc/-/issues/10): 0x00007fff5f7da3cd QuartzCore`CA::Transaction::release_thread(void*) + 209
frame [#11](https://code.videolan.org/videolan/vlc/-/issues/11): 0x00007fff7bf3f27e libsystem_pthread.dylib`_pthread_tsd_cleanup + 534
frame [#12](https://code.videolan.org/videolan/vlc/-/issues/12): 0x00007fff7bf3efbd libsystem_pthread.dylib`_pthread_exit + 79
frame [#13](https://code.videolan.org/videolan/vlc/-/issues/13): 0x00007fff7bf3d6cc libsystem_pthread.dylib`_pthread_body + 351
frame [#14](https://code.videolan.org/videolan/vlc/-/issues/14): 0x00007fff7bf3d56d libsystem_pthread.dylib`_pthread_start + 377
frame [#15](https://code.videolan.org/videolan/vlc/-/issues/15): 0x00007fff7bf3cc5d libsystem_pthread.dylib`thread_start + 13