02d01a68971747f01a270226f6474190736939cf https://codereview.qt-project.org/#/c/216201/ is causing regression in certain use cases when doing offscreen rendering.
Steps to reproduce the issue.
1. Run attached test application which is modified version from Qt example application rendercontrol
2. Click on 'Reset' button
Application crashes with the attached backtrace.
Crash occurs at least on Windows 10 64 bit with msvc2017.
It doesn't reproduce on macOS or Linux.