* dfp-bit.c (DFP_TO_INT): Fix rounding mode.

From-SVN: r119335
This commit is contained in:
Janis Johnson 2006-11-29 23:11:01 +00:00 committed by Janis Johnson
parent 78a5388739
commit 2d42636d4d
2 changed files with 3 additions and 1 deletions

View file

@ -1,5 +1,7 @@
2006-11-29 Janis Johnson <janis187@us.ibm.com>
* config/dfp-bit.c (DFP_TO_INT): Fix rounding mode.
* config/dfp-bit.h (CONTEXT_ROUND): Delete.
(DFP_INIT_ROUNDMODE): Define.
* config/dfp-bit.c: Replace CONTEXT_ROUND with DFP_INIT_ROUNDMODE.

View file

@ -394,7 +394,7 @@ DFP_TO_INT (DFP_C_TYPE x)
decContextDefault (&context, CONTEXT_INIT);
/* Need non-default rounding mode here. */
DFP_INIT_ROUNDMODE (context.round);
context.round = DEC_ROUND_DOWN;
HOST_TO_IEEE (x, &s);
TO_INTERNAL (&s, &n1);