Recursive_mutex lock error on exiting

Building and running the examples/3d/ofBoxExample app on OSX 10.11.5 with XCode 7.3.1 triggers the following error when the app exits:

libc++abi.dylib: terminating with uncaught exception of type std::__1::system_error: recursive_mutex lock failed: Invalid argument

Info:
OSX 10.11.5
XCode 7.3.1
oF 0.9.3 head/master from github at commit f4276f0 (https://github.com/openframeworks/openFrameworks/commit/f4276f05533b828454f88e40b3bc48bfe7eae9ca)

It appears to be happening in the ofEasyCam destructor.

Stack trace:

  • thread #1: tid = 0x588077, 0x00007fff8c7f7f06 libsystem_kernel.dylib`__pthread_kill + 10, queue = ‘com.apple.main-thread’, stop reason = signal SIGABRT
    • frame #0: 0x00007fff8c7f7f06 libsystem_kernel.dylib__pthread_kill + 10 frame #1: 0x0000000100ddd42d libsystem_pthread.dylibpthread_kill + 90
      frame #2: 0x00007fff8eab46e7 libsystem_c.dylibabort + 129 frame #3: 0x00007fff8a8d5f81 libc++abi.dylibabort_message + 257
      frame #4: 0x00007fff8a8fba2f libc++abi.dylibdefault_terminate_handler() + 243 frame #5: 0x00007fff8dc0d6c3 libobjc.A.dylib_objc_terminate() + 124
      frame #6: 0x00007fff8a8f919e libc++abi.dylibstd::__terminate(void (*)()) + 8 frame #7: 0x00007fff8a8f9213 libc++abi.dylibstd::terminate() + 51
      frame #8: 0x00000001000030ff ofBoxExampleDebug__clang_call_terminate + 15 frame #9: 0x00000001003e574e ofBoxExampleDebugofEasyCam::~ofEasyCam(this=) + 104 at ofEasyCam.cpp:45
      frame #10: 0x0000000100003cc1 ofBoxExampleDebugofApp::~ofApp(this=0x0000000101074e00) + 65 at ofApp.h:5 frame #11: 0x0000000100003bc5 ofBoxExampleDebugofApp::~ofApp(this=0x0000000101074e00) + 21 at ofApp.h:5
      frame #12: 0x0000000100003be9 ofBoxExampleDebugofApp::~ofApp(this=0x0000000101074e00) + 25 at ofApp.h:5 frame #13: 0x00007fff8f74bcb8 libc++.1.dylibstd::__1::__shared_weak_count::__release_shared() + 44
      frame #14: 0x00000001003e0ea6 ofBoxExampleDebugofRunApp(std::__1::shared_ptr<ofBaseApp>) [inlined] std::__1::shared_ptr<ofBaseApp>::~shared_ptr() + 109 at memory:4567 frame #15: 0x00000001003e0e9c ofBoxExampleDebugofRunApp(std::__1::shared_ptr) [inlined] std::__1::shared_ptr::~shared_ptr() at memory:4565
      frame #16: 0x00000001003e0e9c ofBoxExampleDebugofRunApp(std::__1::shared_ptr<ofBaseApp>) [inlined] std::__1::shared_ptr<ofBaseApp>::reset() + 10 at memory:4696 frame #17: 0x00000001003e0e92 ofBoxExampleDebugofRunApp(app=) + 89 at ofAppRunner.cpp:171
      frame #18: 0x00000001003e0e07 ofBoxExampleDebugofRunApp(OFSA=<unavailable>) + 37 at ofAppRunner.cpp:164 frame #19: 0x0000000100001a84 ofBoxExampleDebugmain + 100 at main.cpp:12
      frame #20: 0x0000000100001a14 ofBoxExampleDebug`start + 52