Bug 487020 - kcalc from kdeutils trig bug probably because deg/rad/grad uninitialised
kcalc from kdeutils trig bug probably because deg/rad/grad uninitialised
Product: Fedora
Classification: Fedora
Component: kdeutils (Show other bugs)
x86_64 Linux
low Severity medium
: ---
: ---
Assigned To: Ngo Than
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2009-02-23 12:34 EST by Phil Smith
Modified: 2009-03-18 09:43 EDT (History)
6 users (show)

See Also:
Fixed In Version: 4.2.1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2009-03-18 09:39:22 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

External Trackers
Tracker ID Priority Status Summary Last Updated
KDE Software Compilation 181875 None None None Never

  None (edit)
Description Phil Smith 2009-02-23 12:34:37 EST
Description of problem:
kcalc calculates cos(0)=0 if deg/rad/grad is left on initial deg

Version-Release number of selected component (if applicable):

How reproducible:
random: probably depends on random memory

Steps to Reproduce:
1. start kcalc: display says "0"
2. enable Settings->science: display says "deg"
3. click "cos" button
4. get answer 0 which is the result of a "cos" of the initial "0" in degrees
5. click on rad
6. click on deg
7. click "cos" button
8. get correct answer 1
Actual results:
answer 0 first time (step 4), answer 1 second time (step 8)

Expected results:
answer 1 both times

Additional info:
Looks like _angle_mode is never initialised in the code even though "deg" button is selected on startup
Comment 1 Steven M. Parrish 2009-03-16 20:32:57 EDT
Thank you for the bug report.  This issue needs to be addressed by the upstream developers.  Please submit a report at http://bugs.kde.org. You are requested to add the bugzilla link here for tracking purposes. Please make sure the bug isn't already in the upstream bug tracker before filing it.
Comment 2 Phil Smith 2009-03-18 09:33:33 EDT
Searched and submitted
... now resolved.
Later found to be duplicate of
which was resolved by SVN commit 919386:
  "BUG: 181875
  kcalc was not initializing the angle mode. This caused the trig functions to
  be noops. The fix was to save/restore the angle mode as a configuration item.
  The angle mode is now initialized from the config. Also did the same for
  the numeric base"
Comment 3 Rex Dieter 2009-03-18 09:39:22 EDT
OK, should be fixed in kdeutils-4.2.1 then, pushed to stable updates yesterday.
Comment 4 Kevin Kofler 2009-03-18 09:43:49 EDT
Right, 4.2 branch commit here:

This went into 4.2.1.

Note You need to log in before you can comment on or make changes to this bug.