Share

Celestia

Tracker: Bugs

5 Linux - crash? when using very slow time - ID: 2059401
Last Update: Comment added ( nick_warne )

Running 1.5.1 on Slackware 12.1, KDE interface.

This really is something I stumbled on, not really a practical issue.

I accidently pressed the 'k' key continuously instead of some other key,
and Celestia crashed on me.

This is repeatable.

The time indicator goes:

10x slow
100x slow
1000x slow
10,000x slow
100,000x slow
,000,000x slow (??)
10,000,000x slow
100,000,000x slow
,000,000,000x slow (??)
10,000,000,000x slow
100,000,000,000,000x slow
<crash>

Running through gdb with enable-debug=ll reveals nothing (application
closed normally).

Reading the code I see that the time reduction should be stopped if <
MinimumTimeRate (static const double MinimumTimeRate = 1.0e-15) - but it
appears not to happen.

Nick


Nick Warne ( nick_warne ) - 2008-08-19 10:10

5

Open

None

Nobody/Anonymous

None

None

Public


Comment ( 1 )

Date: 2008-08-20 06:33
Sender: nick_warneSourceForge.net Donor


OK, I fixed this up. It appears what was happening is an overflow when
getting past 1e-11 that caused the crash. I also set the fastest/slowest
time rates down a little for both values (this should be suffice, shouldn't
it??).

Secondly, the top right hand timerate displayed ,000,000x and
,000,000,000x etc. because of the way floating math is done. The actual
values (e.g.) was 999999.998765465 etc., so the printf format bulks.
Setting ceil() here fixes this up too.

Patch attached.

Nick
File Added: speedrate.patch


Attached File ( 1 )

Filename Description Download
speedrate.patch Patch to fix overflow and printf format on timerates Download

Change ( 1 )

Field Old Value Date By
File Added 289483: speedrate.patch 2008-08-20 06:33 nick_warne