CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

ERROR->Foam::sigSegv::sigHandler(int)

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 21, 2015, 22:04
Default sigSegv ERROR caused by SLPtrList<>
  #1
Member
 
Karelke Yu
Join Date: Dec 2014
Posts: 96
Rep Power: 11
cfdopenfoam is on a distinguished road
greetings to everyone.

your checking this thread has made me thankful. i now encounter a tough problem, which maybe C++ programming involved.

i develop mySolver in OF-2.3.0 on ubuntu-12.04 and everything seems to be OK. it can run normally and give the expected results. however, problem comes with the last statement of the main function, "return 0". here is all what i get:

Code:
#0  Foam::error::printStack(Foam::Ostream&) in "/home/yk/OpenFOAM/OpenFOAM-2.3.0/platforms/linux64GccDPOpt/lib/libOpenFOAM.so"
#1  Foam::sigSegv::sigHandler(int) in "/home/yk/OpenFOAM/OpenFOAM-2.3.0/platforms/linux64GccDPOpt/lib/libOpenFOAM.so"
#2   in "/lib/x86_64-linux-gnu/libc.so.6"
#3  Uninterpreted: 
Segmentation fault (core dumped)
i googled the sigSegv error. and i now know it is caused by an application accessing memory outside the allocated space. but how could i address the problem efficiently? why the problem comes with "return 0", the last statement of the main function, rather than something in the time loop? what does the "return 0" actually do? are there some tools or debuggers i could use to fix the problem?

any idea will make my day. thanks for the attention.

best regards,
jhyk

Last edited by cfdopenfoam; May 22, 2015 at 21:52.
cfdopenfoam is offline   Reply With Quote

Old   May 22, 2015, 07:22
Default
  #2
Member
 
Karelke Yu
Join Date: Dec 2014
Posts: 96
Rep Power: 11
cfdopenfoam is on a distinguished road
some struggling...the problem is addressed but not solved.
it comes from the SLPtrList<> (in src/OpenFOAM/containers/LinkedLists/user/SLPtrList.H), which unfortunately i know nothing about.
when debugging with gdb, i find that a class containing an object of SLPtrList<> could not destruct normally. i think this is the problem makes the program could not return 0.

so, could someone kindly say something about this confusing SLPtrList<>? or where i can learn more about it?
any idea will be greatly appreciated!
cfdopenfoam is offline   Reply With Quote

Old   September 20, 2015, 15:21
Default
  #3
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,974
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Greetings,

I guess I'm too late to answer now, but in theory:
  • One possible reason for the problem is possibly related to the OpenFOAM version you're using was built with a set of options and utilities, but then you built the solver with another version.
  • Another possibility is due to incorrect use of a list of type SLPtrList.
Either way, without seeing the source code modifications you made, it's nearly impossible to diagnose the origin problem.


Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   June 11, 2018, 07:49
Default
  #4
Member
 
Join Date: Feb 2018
Posts: 91
Rep Power: 8
charles4allme is on a distinguished road
Hello @cfdopenfoam

Were you able to discover what the problem is?

Best regards
charles4allme is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 18:09.