summaryrefslogtreecommitdiff
path: root/src/atan.c
diff options
context:
space:
mode:
authorvlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2011-05-04 23:46:17 +0000
committervlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2011-05-04 23:46:17 +0000
commitc428de930ce7f3b0356c730ae9b1df5a08ac9c83 (patch)
treef8ecfd2a8cfdb19421f65f2684b02d9f4fa49b50 /src/atan.c
parentf72b6df904ed827e0a0f69dd0f4b1bcd6d3ddccf (diff)
downloadmpfr-c428de930ce7f3b0356c730ae9b1df5a08ac9c83.tar.gz
[src/atan.c] Fixed bug in mpfr_atan: mpfr_check_range was called on the
unrounded result (no longer allocated) instead of the rounded result. Consequence of this bug: possible incorrect or invalid result and/or incorrect flags if either the unrounded result or rounded result is not in the current exponent range. Or possibly worse if the memory used by the unrounded result is modified before the return of the function. git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@7667 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'src/atan.c')
-rw-r--r--src/atan.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/atan.c b/src/atan.c
index 064047467..9090f14f1 100644
--- a/src/atan.c
+++ b/src/atan.c
@@ -433,5 +433,5 @@ mpfr_atan (mpfr_ptr atan, mpfr_srcptr x, mpfr_rnd_t rnd_mode)
MPFR_GROUP_CLEAR (group);
MPFR_SAVE_EXPO_FREE (expo);
- return mpfr_check_range (arctgt, inexact, rnd_mode);
+ return mpfr_check_range (atan, inexact, rnd_mode);
}