summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/features.h4
-rw-r--r--libc/stdio/printf.c2
-rw-r--r--libc/sysdeps/linux/common/syscalls.c1
-rw-r--r--libc/sysdeps/linux/sh/longjmp.c4
-rw-r--r--libm/e_asin.c2
-rw-r--r--libm/e_exp.c4
-rw-r--r--libm/e_rem_pio2.c2
-rw-r--r--libm/s_expm1.c2
8 files changed, 12 insertions, 9 deletions
diff --git a/include/features.h b/include/features.h
index 230baedd7..ca3641688 100644
--- a/include/features.h
+++ b/include/features.h
@@ -422,8 +422,8 @@ uClibc was built without large file support enabled.
#define __builtin_expect(x, expected_value) (x)
#endif
-#define likely(x) __builtin_expect((x),1)
-#define unlikely(x) __builtin_expect((x),0)
+#define likely(x) __builtin_expect(((int)(x)),1)
+#define unlikely(x) __builtin_expect(((int)(x)),0)
/* --- this is added to integrate linuxthreads */
#define __USE_UNIX98 1
diff --git a/libc/stdio/printf.c b/libc/stdio/printf.c
index de50ed4e5..14e3f2173 100644
--- a/libc/stdio/printf.c
+++ b/libc/stdio/printf.c
@@ -764,7 +764,7 @@ extern int _ppfs_parsespec(ppfs_t *ppfs)
int n;
int argtype[MAX_ARGS_PER_SPEC+2];
int argnumber[3]; /* width, precision, 1st data arg */
- unsigned int conv_num;
+ unsigned int conv_num = 0;
static const char spec_flags[] = SPEC_FLAGS;
static const char spec_chars[] = SPEC_CHARS;/* TODO: b? */
static const char spec_ranges[] = SPEC_RANGES;
diff --git a/libc/sysdeps/linux/common/syscalls.c b/libc/sysdeps/linux/common/syscalls.c
index 4acd0401c..ff7c38478 100644
--- a/libc/sysdeps/linux/common/syscalls.c
+++ b/libc/sysdeps/linux/common/syscalls.c
@@ -35,6 +35,7 @@
#include <errno.h>
#include <sys/types.h>
#include <sys/syscall.h>
+#include <endian.h>
//#define __NR_exit 1
diff --git a/libc/sysdeps/linux/sh/longjmp.c b/libc/sysdeps/linux/sh/longjmp.c
index a17147d5f..dd4f684ad 100644
--- a/libc/sysdeps/linux/sh/longjmp.c
+++ b/libc/sysdeps/linux/sh/longjmp.c
@@ -24,6 +24,8 @@
#include <setjmp.h>
#include <signal.h>
+extern int __longjmp(char *env, int val);
+extern int __sigprocmask(int how, const sigset_t *set, sigset_t *oldset);
/* Set the signal mask to the one specified in ENV, and jump
to the position specified in ENV, causing the setjmp
@@ -36,7 +38,7 @@ void __libc_siglongjmp (sigjmp_buf env, int val)
(sigset_t *) NULL);
/* Call the machine-dependent function to restore machine state. */
- __longjmp (env[0].__jmpbuf, val ?: 1);
+ __longjmp ((char *) env[0].__jmpbuf, val ?: 1);
}
__asm__(".weak longjmp; longjmp = __libc_siglongjmp");
diff --git a/libm/e_asin.c b/libm/e_asin.c
index 46b93d8c0..210fdbf3b 100644
--- a/libm/e_asin.c
+++ b/libm/e_asin.c
@@ -77,7 +77,7 @@ qS4 = 7.70381505559019352791e-02; /* 0x3FB3B8C5, 0xB12E9282 */
double x;
#endif
{
- double t,w,p,q,c,r,s;
+ double t=0.0,w,p,q,c,r,s;
int32_t hx,ix;
GET_HIGH_WORD(hx,x);
ix = hx&0x7fffffff;
diff --git a/libm/e_exp.c b/libm/e_exp.c
index 734166733..f92910e85 100644
--- a/libm/e_exp.c
+++ b/libm/e_exp.c
@@ -111,8 +111,8 @@ P5 = 4.13813679705723846039e-08; /* 0x3E663769, 0x72BEA4D0 */
#endif
{
double y;
- double hi = 0;
- double lo = 0;
+ double hi = 0.0;
+ double lo = 0.0;
double c;
double t;
int32_t k=0;
diff --git a/libm/e_rem_pio2.c b/libm/e_rem_pio2.c
index 85dbaac6d..e98c699cd 100644
--- a/libm/e_rem_pio2.c
+++ b/libm/e_rem_pio2.c
@@ -90,7 +90,7 @@ pio2_3t = 8.47842766036889956997e-32; /* 0x397B839A, 0x252049C1 */
double x,y[];
#endif
{
- double z=0,w,t,r,fn;
+ double z=0.0,w,t,r,fn;
double tx[3];
int32_t e0,i,j,nx,n,ix,hx;
u_int32_t low;
diff --git a/libm/s_expm1.c b/libm/s_expm1.c
index 79783d9ba..5e7e9d84f 100644
--- a/libm/s_expm1.c
+++ b/libm/s_expm1.c
@@ -138,7 +138,7 @@ Q5 = -2.01099218183624371326e-07; /* BE8AFDB7 6E09C32D */
double x;
#endif
{
- double y,hi,lo,c=0,t,e,hxs,hfx,r1;
+ double y,hi,lo,c=0.0,t,e,hxs,hfx,r1;
int32_t k,xsb;
u_int32_t hx;