Program received signal SIGSEGV, Segmentation fault
ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
there is a command ldconfig. it uses the file /etc/ld.so.conf and the dir /etc/ld.so.conf.d to look for libraries. You can see at this moment it found libs in /lib/tls/i686/cmov and /opt/hdf5-1.8.12-linux-shared/lib too and I have no idea what kind of libs are stored in those dirs. Probably you need to reconfigure it. Segfault is probably caused by using incompatible libraries. Try to set LD_LIBRARY_PATH=/lib.
Looks like no more SIGSEGV after adding: LD_LIBRARY_PATH=/lib
Quote:
gdb test
GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 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 "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /home/likewise-open/WIN2K/gfm01/brad/wn-branch-parallel/bin/test...done.
(gdb) run
Starting program: /home/likewise-open/WIN2K/gfm01/brad/wn-branch-parallel/bin/test
Program exited with code 0120.
but what does it mean code 0120?
Will test it and let you know if it is 100% solved
the exit code is more or less a random value, because you have not specified anything. Try to insert return 0; or similar at the end of the main function.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.