gpt4 book ai didi

c++ - 由于 KERNELBASE.dll 错误,GDB 无法运行程序

转载 作者:塔克拉玛干 更新时间:2023-11-03 02:15:20 32 4
gpt4 key购买 nike

我最近才开始遇到这个问题,我不知道它是什么时候开始出现的/是什么原因造成的。

我这里有这个简单的测试程序:

#include <iostream>

int main()
{
return 0;
}

但是当我尝试正常运行它时,它会创建一个堆栈转储。

Stack trace:
Frame Function Args
00CBC498 6101D93A (00000198, 0000EA60, 000000A4, 00CBC508)
00CBC5C8 610E2F3F (00000000, 60FC04E8, 00CBC658, 7794ABEE)

然而,当我尝试在 GDB 中运行它时,它显然无法运行。

gdb: unknown target exception 0x406d1388 at 0x778edae8

Program received signal ?, Unknown signal.
0x778edae8 in RaiseException ()
from /cygdrive/c/WINDOWS/SYSTEM32/KERNELBASE.dll
(gdb) n
Single stepping until exit from function RaiseException,
which has no line number information.
[Thread 14880.0x11ac exited with code 1080890248]
[Thread 14880.0x3fd8 exited with code 1080890248]
[Thread 14880.0x3b24 exited with code 1080890248]
[Inferior 1 (process 14880) exited with code 010033211610]

我的编译器是这样设置的:

g++ -g -std=c++1y -Wall -c main.cpp -o main.o main.cpp compiled... 
g++ -g -std=c++1y -Wall -o a main.o Successfully compiled!

知道我在这里做错了什么吗?我使用的平台是 Windows,我使用 Cygwin 作为我的开发环境。

注意:无论我在 main.cpp 中有什么,我仍然会遇到上述 GDB 错误。

另请注意:以下是 a.exe 可执行文件中的其他文件:

我以前需要 cygboost_filesystem.dll 让 boost_filesystem 工作,我需要 libgcc_s_sjlj-1.dlllibstdc++6 因为没有他们就不行。

最佳答案

将 gdb 更新到 7.11.1-1 实验发布版本。

Details of GDB bug

关于c++ - 由于 KERNELBASE.dll 错误,GDB 无法运行程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39321216/

32 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com