下面的运行时错误是什么意思:“在没有活动异常的情况下调用终止”。 [英] What does the following runtime error mean: "terminate called without an active exception\n Aborted"
问题描述
错误扰乱了我两天左右:当运行代码时,我有一个运行时错误终止调用没有活动异常\\\
中止,为什么?
The bug disturbed me about two days: when running the code I have a runtime error of "terminate called without an active exception\n Aborted",why?
我尝试找到代码并找到行可能会退出代码xx = new int [num],我的测试用例中的num是大约640000(64MB内存到新)。当我设置num小得多的10,这是确定,但我的代码得到一个错误的答案这一次。
I try to locate the code and find the line may be exit the code "xx = new int [num]", the num in my test case is about 640000(64MB memory to new). when I set the num much smaller as 10, it is OK, but my code get a wrong answer this time.
我试图删除所有的try /但是仍然有这个错误。
I try to delete all the "try/catch" Clause but still have this error.
同样我//所有调用xx = new int [num]子句的函数,错误仍然存在,时间我找到的代码可能退出是一个正常的for循环。
Also I // all the function which call the "xx = new int [num]" clause, the error still exist, and this time I locate the code may exit is a normal "for loop".
所有的情况下通过编译器,有没有遇到这个错误运行你的代码? !
All the case passed the compiler, have u ever met this error in running your code?Thank you!
我//一些删除子句并得到以下错误:
* glibc detected * ./ESMF_RegridWeightGen:munmap_chunk :invalid pointer:0x00000000005cd376 *
I // some delete clause and get the error below: * glibc detected * ./ESMF_RegridWeightGen: munmap_chunk(): invalid pointer: 0x00000000005cd376 *
推荐答案
当我看到这个错误时,在其封装的线程退出之前,该线程对象被销毁。
When I've seen this error, it was caused by the thread object destructing before the thread it encapsulated has exited.
这篇关于下面的运行时错误是什么意思:“在没有活动异常的情况下调用终止”。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!