DMS rounding error

Bug #1289846 reported by Se Li
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Stellarium
Fix Released
Low
Alexander Wolf

Bug Description

When Stellarium displays a number as degrees, minutes and seconds, a rounding error occurs if the number of degrees is negative, minutes are zero and seconds approach 60. For example, check the galactic latitude of the sun as seen from Berlin, Germany on 8 March 2014 (today) at 18:22:15 local time (UTC+0100). It is −58°00'59.9''a few seconds earlier, but the value is now displayed as −58°4294967295'0.00'' and a few seconds later it is −58°01'00.0''. I've observed this for other objects at other times, but only for a short time as a values move from −x°00'59.9" towards −x°01'00.0" (for a positive integer x).

Related branches

Changed in stellarium:
status: New → Confirmed
milestone: none → 0.13.0
importance: Undecided → Medium
importance: Medium → Low
Revision history for this message
Alexander Wolf (alexwolf) wrote :
Changed in stellarium:
assignee: nobody → Alexander Wolf (alexwolf)
status: Confirmed → Fix Committed
Revision history for this message
Se Li (se-li) wrote :

Ah! I thought there was something fishy about this section, but didn't look close enough. :-) There's still what I think is a minor flaw: in lines 216 and 221, a floating point value is assigned to unsigned int variables. Not sure if the conversion happens at compile or at run time.

Changed in stellarium:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.