I just had a crash when running my game in fullscreen from the editor (the editor didn’t crash). Here’s the bit from the console and I’ve uploaded the referenced file (_crash.zip).
macOS 11.4, MBP 13", 2020, 2.3 GHz, i7, 32GB, Intel Iris Plus Graphics 1536MB
I'm also running an external 4K LG Monitor.
INFO:DLIB: Log server started on port 51342
INFO:ENGINE: Target listening with name: MacBook-Pro.local - ::1 - Darwin
INFO:ENGINE: Engine service started on port 51343
INFO:ENGINE: Defold Engine 1.2.184 (1f57126)
2021-07-13 08:33:10.308 Defold[2860:102994] void * _Nullable NSMapGet(NSMapTable * _Nonnull, const void * _Nullable): map table argument is NULL
WARNING:GRAPHICS: Trying OpenGL 3.1 compat mode
INFO:CRASH: Successfully wrote Crashdump to file: /Users/bryanrieger/Library/Application Support/Defold/_crash
ERROR:CRASH: CALL STACK:
#0 pc 0x91d7d libc++abi.dylib _sigtramp+29
Yup. I’ve attached the macOS generated crash report.
Tick ‘Display > Fullscreen’. Run via ⌘ + B. Both the Mac and the external screens go black, Apple Music stops, then everything appears again (incl. Apple Music starting to play again) and the crash report prompt is shown.
I even get this behaviour on a new, empty desktop project where the only thing I’ve done is check the ‘Display > Fullscreen’ checkbox.
Running without ‘Display > Fullscreen’ works just fine, and Apple Music also continues to play as expected. Also, attempting to run the project (in fullscreen) with nothing else open (just the Defold editor) results in the same crash of the runtime.
We use strlen() in 3 places there, and I’m not yet sure which one is causing the problem.
I’ll make a special version with some more debug info you can test…
Here’s the next version (which uses glGetString(GL_EXTENSIONS); instead.
I wasn’t able to test it myself, since I cannot create that compatibility mode myself.
INFO:DLIB: Log server started on port 54143
INFO:ENGINE: Target listening with name: Bryans-MacBook-Pro.local - ::1 - Darwin
INFO:ENGINE: Engine service started on port 8001
INFO:ENGINE: Defold Engine 1.2.185 (ef87996)
2021-07-13 12:51:57.470 dmengine[5093:264470] void * _Nullable NSMapGet(NSMapTable * _Nonnull, const void * _Nullable): map table argument is NULL
WARNING:GRAPHICS: Trying OpenGL 3.1 compat mode
Assertion failed: (extensions), function OpenGLOpenWindow, file …/src/opengl/graphics_opengl.cpp, line 911.
INFO:CRASH: Successfully wrote Crashdump to file: /Users/bryanrieger/Library/Application Support/Defold/_crash
ERROR:CRASH: CALL STACK:
#0 pc 0x91d7d libc++abi.dylib _sigtramp+29
zsh: abort ./dmengine
Ok, thanks. Then I know for sure that the glGetString(GL_EXTENSIONS) won’t work.
Hmm, I’ll have to test it out more, on my own laptop, to see if I can reproduce it.
There were two dmengine files in the .zip. This is from the x86_64-darwin folder:
Applications/Desktop game % ./dmengine
INFO:DLIB: Log server started on port 49358
INFO:ENGINE: Target listening with name: Bryans-MacBook-Pro.local - ::1 - Darwin
INFO:ENGINE: Engine service started on port 8001
INFO:ENGINE: Defold Engine 1.2.185 (ef87996)
2021-07-14 06:04:45.249 dmengine[696:7957] void * _Nullable NSMapGet(NSMapTable * _Nonnull, const void * _Nullable): map table argument is NULL
WARNING:GRAPHICS: Trying OpenGL 3.1 compat mode
Assertion failed: (extensions), function OpenGLOpenWindow, file …/src/opengl/graphics_opengl.cpp, line 911.
INFO:CRASH: Successfully wrote Crashdump to file: /Users/bryanrieger/Library/Application Support/Defold/_crash
ERROR:CRASH: CALL STACK:
#0 pc 0x91d7d libc++abi.dylib _sigtramp+29
zsh: abort ./dmengine
And this is from the dmengine file in the root dmengine_beta185_ogl_debug dir:
INFO:DLIB: Log server started on port 49435
INFO:ENGINE: Target listening with name: Bryans-MacBook-Pro.local - ::1 - Darwin
INFO:ENGINE: Engine service started on port 8001
INFO:ENGINE: Defold Engine 1.2.185 (ef87996)
INFO:ENGINE: Loading data from: build/default
INFO:ENGINE: Initialised sound device ‘default’
INFO:DLIB: SSDP: Started on address 10.0.0.63
INFO:DLIB: SSDP: Done on address 10.0.0.63