~ubuntu-branches/ubuntu/natty/eglibc/natty-security

« back to all changes in this revision

Viewing changes to sysdeps/ieee754/ldbl-128/s_cosl.c

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Klose
  • Date: 2009-08-03 10:17:12 UTC
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: james.westby@ubuntu.com-20090803101712-n74r7xge7cwubmka
Tags: upstream-2.10.1
ImportĀ upstreamĀ versionĀ 2.10.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
44
44
 *      TRIG(x) returns trig(x) nearly rounded
45
45
 */
46
46
 
 
47
#include <errno.h>
47
48
#include "math.h"
48
49
#include "math_private.h"
49
50
 
66
67
          return __kernel_cosl(x,z);
67
68
 
68
69
    /* cos(Inf or NaN) is NaN */
69
 
        else if (ix>=0x7fff000000000000LL) return x-x;
 
70
        else if (ix>=0x7fff000000000000LL) {
 
71
            if (ix == 0x7fff000000000000LL) {
 
72
                GET_LDOUBLE_LSW64(n,x);
 
73
                if (n == 0)
 
74
                    __set_errno (EDOM);
 
75
            }
 
76
            return x-x;
 
77
        }
70
78
 
71
79
    /* argument reduction needed */
72
80
        else {