noximus / cosmographia

Automatically exported from code.google.com/p/cosmographia
0 stars 0 forks source link

Linux segmentation fault on program startup #27

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Compile the latest source of cosmographia
2. Launch the executable
3. The program dies with Segmentation Fault

What is the expected output? What do you see instead?

See above

What version of the product are you using? On what operating system?

Latest source checked out from SVN (r821)
Operating system is Ubuntu 12.10

Please provide any additional information below.

I compiled the source as debug build. I also run the strace command to trace 
the system calls and signals.

Here follow the last output of "strace" before the segmentation fault. It 
appears that the program dies while reading the file "earth.atmscat"

--------------------------------------------
open("/home/daniele/installazioni/cosmographia/cosmographia-read-only/data/earth
.atmscat", O_RDONLY|O_CLOEXEC) = 22
fcntl(22, F_SETFD, FD_CLOEXEC)          = 0
fstat(22, {st_mode=S_IFREG|0664, st_size=5767244, ...}) = 0
fstat(22, {st_mode=S_IFREG|0664, st_size=5767244, ...}) = 0
fstat(22, {st_mode=S_IFREG|0664, st_size=5767244, ...}) = 0
read(22, 
"atmscatr\1\0\0\0\0\0\0A\311\200\2736\341\34267\364?\3377\232\231\231?"..., 
5767244) = 5767244
brk(0x4216000)                          = 0x4216000
brk(0x4797000)                          = 0x4797000
brk(0x4b97000)                          = 0x4b97000
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++
Segmentation fault
---------------------------------------------------------------------------

Original issue reported on code.google.com by llanie...@gmail.com on 8 Apr 2014 at 8:47

GoogleCodeExporter commented 9 years ago
I am seeing a similar response when compiling on Windows 7 x64 using Microsoft 
Visual C++ Compiler 11.0 (amd64) compiler. 

Original comment by ewf...@gmail.com on 9 Jun 2014 at 12:47

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
The problem comes from the use of Texture3D before glew is effectively 
initialized.
There's should be some QT expert understanding the threading sync problem, but 
a simple workaround is to add (in main.cpp line 111):

    QCoreApplication::processEvents(QEventLoop::AllEvents,100);

The splash sequence is a bit dark, but the program start.
see attached file for changes.

Original comment by jp_bruy...@hotmail.com on 15 Feb 2015 at 6:57

Attachments: