此应用程序已请求运行时以异常方式终止它 QT C++

This application has requested the runtime to terminate it in an unusual way QT C++

本文关键字:终止 方式 QT C++ 异常 应用程序 请求 运行时      更新时间:2023-10-16

我正在开发一个QT C++的十五个益智游戏。游戏有时运行良好,有时在运行过程中崩溃。我不知道问题所在。我查看了不同的论坛,发现了不同的建议。有人说此错误是由于缺少dll等造成的。

出现一个窗口,下面显示错误

Microsoft Visual C++ Runtime Library
This application has requested the runtime to terminate it in an unusual way.
Please contact the application's support team for more information. 

我解决了这个问题:实际上我正在访问一个不可用的矢量位置。 assert()帮助我排除故障。谢谢@DNT