Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#8389 closed bug (fixed)

Computation error

Reported by: mmadia Owned by: jscipione
Priority: normal Milestone: R1
Component: Applications/DeskCalc Version: R1/Development
Keywords: gsoc2012 Cc:
Blocked By: Blocking:
Platform: All

Description (last modified by mmadia)

The following calculation 12*1058.33333333333333 will result in an error 127. . To note, removing any single digit will allow DeskCalc to calculate it properly.

Noticed on hrev43819 - gcc2h.

Attachments (1)

DeskCalcRoundingProblem.patch (1.4 KB ) - added by ahenriksson 13 years ago.

Download all attachments as: .zip

Change History (7)

comment:1 by mmadia, 13 years ago

Description: modified (diff)

comment:2 by Amanjot, 13 years ago

I am working on fixing this bug.

by ahenriksson, 13 years ago

comment:3 by ahenriksson, 13 years ago

patch: 01

comment:4 by ahenriksson, 13 years ago

I assumed that Amanjot had forgotton all about this. If not, and they come back with an awesome patch then so much better. :)

The problem is that the function that rounds a calculated number to fit in the display window, in its eagerness to remove trailing zeros, forgets to check if they occur after or before the decimal point.

comment:5 by jscipione, 13 years ago

Resolution: fixed
Status: newclosed

Fixed in hrev43961 Thanks ahenriksson! Is this fix for GSOC?

comment:6 by korli, 13 years ago

Keywords: gsoc2012 added
Note: See TracTickets for help on using tickets.