pioneerspacesim / pioneer

A game of lonely space adventure
https://pioneerspacesim.net
1.64k stars 380 forks source link

Crash on hyperjump #5909

Closed impaktor closed 3 months ago

impaktor commented 3 months ago

Observed behaviour

Crash when hyperjumping. Initially I though it was due to me making an illegal jump, or from a partially compiled master. I've removed build/ directory and re-compiled. Still crashes.

Steps to reproduce


Thread 1 "pioneer" received signal SIGSEGV, Segmentation fault.
0x000055555572c18d in Background::Starfield::Draw (this=0x55556bea3ee0) at /home/me/usr/src/pioneer/src/Background.cpp:613
613             Graphics::VertexBuffer *buffer = m_animMesh->GetVertexBuffer();
(gdb) bt
#0  0x000055555572c18d in Background::Starfield::Draw (this=0x55556bea3ee0) at /home/me/usr/src/pioneer/src/Background.cpp:613
#1  0x000055555573ea03 in Camera::Draw (this=0x55555d182d80, excludeBody=excludeBody@entry=0x0) at /home/me/usr/src/pioneer/src/Camera.cpp:290
#2  0x00005555557eb935 in WorldView::Draw3D (this=0x555556848c00) at /usr/include/c++/14.2.1/bits/unique_ptr.h:193
#3  0x000055555561b7fa in GameLoop::Update (this=0x555555bf5310, deltaTime=0.0163164809) at /home/me/usr/src/pioneer/src/Pi.cpp:1011
#4  0x00005555555ed72f in Application::Run (this=0x555555bf50b0) at /home/me/usr/src/pioneer/src/core/Application.cpp:193
#5  0x00005555555e6584 in main (argc=<optimized out>, argv=<optimized out>) at /home/me/usr/src/pioneer/src/Pi.h:144
(gdb) Quit

My pioneer version (and OS): f59dfb09c

I recently did a system update, so got new version of gcc (14.2.1), and friends

impaktor commented 3 months ago

Turns out I had starfield density = 0 (not sure how that happened). I deem this to be a duplicate of #5880, as @zonkmachine pointed out in IRC