GDB警告:在0x7ffff7ffd000添加的符号文件系统提供的DSO中未找到可加载部分 [英] GDB Warning: Loadable section not found in added symbol-file system-supplied DSO at 0x7ffff7ffd000

查看:200
本文介绍了GDB警告:在0x7ffff7ffd000添加的符号文件系统提供的DSO中未找到可加载部分的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

abijith bufferOverFlow $ gdb a.out
GNU gdb (GDB) 7.6
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /home/abijith/Project/Security/bufferOverFlow/a.out...done
(gdb) r
Starting program: /home/abijith/Projec2qt/Security/bufferOverFlow/a.out 
warning: no loadable sections found in added symbol-file system-supplied 
SO at 0x7ffff7ffd000

打印字符串并返回的简单程序。我可以通过输入 ./a.out 直接执行它。但是当我在gdb中运行它时,会出现上述错误。我尝试使用 -g 标志编译代码,而不使用它。两次都给出了相同的结果。任何人都可以帮我解决这个问题??

I wrote a simple program which prints a string and returns. I was able to execute it directly, by typing "./a.out". But when I run it in gdb the error mentioned above happens. I tried compiling the code using the "-g" flag and without using it. Both time it gave the same result. Can anyone help me with this issue??

推荐答案

那个消息,

That message,

warning: no loadable sections found in added symbol-file system-supplied 

中找不到可加载部分

SO 0x7ffff7ffd000

SO at 0x7ffff7ffd000

是一个警告,它不会阻止GCC运行 a.out ;至少,它不应该。

is a warning that does not prevent GCC from running a.out; at least, it should not.

这是说有一个动态加载的对象被 a.out 使用缺少符号。没有关于a.out本身。

It is saying that there's a dynamically loaded object used by a.out that is missing symbols. Nothing about a.out itself.

您可以尝试将a.out构建为静态可执行文件;像这样:

You can try to build a.out as a static executable; like this:

gcc -static a.c

显然,需要添加任何其他编译器参数。

Obviously, add any other compiler arguments needed.

作为一个静态可执行文件,您不会从GCC获得警告。这些符号可能仍然丢失,但不应该影响程序的执行。

As a static executable, you won't get that warning from GCC. Those symbols may still be missing, but it should not affect execution of the program.

这篇关于GDB警告:在0x7ffff7ffd000添加的符号文件系统提供的DSO中未找到可加载部分的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆