diff --git a/lib/libc/localtime_r.c b/lib/libc/localtime_r.c index cce996511b..c1cf0ccb18 100644 --- a/lib/libc/localtime_r.c +++ b/lib/libc/localtime_r.c @@ -34,7 +34,7 @@ localtime_r(const time_t *const timep, struct tm *p_tm) struct tm * localtime_r(const time_t *const timep, struct tm *p_tm) { - static tm* tmp; + static struct tm* tmp; tmp = localtime(timep); if (tmp) { memcpy(p_tm, tmp, sizeof(struct tm)); diff --git a/lib/libc/setenv.c b/lib/libc/setenv.c index 35dd2f2d3a..c5594872aa 100644 --- a/lib/libc/setenv.c +++ b/lib/libc/setenv.c @@ -21,8 +21,10 @@ \********************************************************************/ #include +#include #include #include +#include "setenv.h" /* This setenv() papers over the brokenness of of systems that only * have putenv() which takes ownership of the pointer you give it, diff --git a/lib/libc/setenv.h b/lib/libc/setenv.h index 9291aef6ab..9f7339e1ca 100644 --- a/lib/libc/setenv.h +++ b/lib/libc/setenv.h @@ -20,8 +20,8 @@ * \********************************************************************/ -#ifndef GNC_CORE_UTILS_H -#define GNC_CORE_UTILS_H +#ifndef __SETENV_H +#define __SETENV_H #include "config.h" @@ -31,3 +31,4 @@ int setenv(const char *name, const char *value, int overwrite); int unsetenv(const char *name); #endif +#endif