aboutsummaryrefslogtreecommitdiff
path: root/src/helper
diff options
context:
space:
mode:
Diffstat (limited to 'src/helper')
-rw-r--r--src/helper/fileio.c1
-rw-r--r--src/helper/jim.c2
-rw-r--r--src/helper/replacements.c1
-rw-r--r--src/helper/replacements.h2
-rw-r--r--src/helper/time_support.c3
5 files changed, 4 insertions, 5 deletions
diff --git a/src/helper/fileio.c b/src/helper/fileio.c
index 84e1f84..d4cd75c 100644
--- a/src/helper/fileio.c
+++ b/src/helper/fileio.c
@@ -43,7 +43,6 @@
#include <errno.h>
#include <ctype.h>
-int fileio_close(fileio_t *fileio);
int fileio_dispatch_read(fileio_t *fileio, u32 size, u8 *buffer, u32 *size_read);
int fileio_open_local(fileio_t *fileio)
diff --git a/src/helper/jim.c b/src/helper/jim.c
index bcea7c5..7f21b43 100644
--- a/src/helper/jim.c
+++ b/src/helper/jim.c
@@ -11979,7 +11979,7 @@ static int Jim_EnvCoreCommand(Jim_Interp *interp, int argc,
if (argc == 1) {
-#ifndef _WIN32
+#if !defined(_WIN32) && !defined(__USE_GNU)
extern char **environ;
#endif
diff --git a/src/helper/replacements.c b/src/helper/replacements.c
index 9f1312c..cc0c242 100644
--- a/src/helper/replacements.c
+++ b/src/helper/replacements.c
@@ -64,6 +64,7 @@ void *fill_malloc(size_t size)
return t;
}
+#define IN_REPLACEMENTS_C
#include "replacements.h"
#include <stdio.h>
diff --git a/src/helper/replacements.h b/src/helper/replacements.h
index 8e1e51d..18c9670 100644
--- a/src/helper/replacements.h
+++ b/src/helper/replacements.h
@@ -103,9 +103,11 @@ struct timezone;
extern int gettimeofday(struct timeval *tv, struct timezone *tz);
#endif
+#ifndef IN_REPLACEMENTS_C
/**** clear_malloc & fill_malloc ****/
void *clear_malloc(size_t size);
void *fill_malloc(size_t size);
+#endif
/*
* Now you have 3 ways for the malloc function:
diff --git a/src/helper/time_support.c b/src/helper/time_support.c
index 6968ab7..bc52e9c 100644
--- a/src/helper/time_support.c
+++ b/src/helper/time_support.c
@@ -33,9 +33,6 @@
#include <stdlib.h>
-int timeval_subtract(struct timeval *result, struct timeval *x, struct timeval *y);
-int timeval_add(struct timeval *result, struct timeval *x, struct timeval *y);
-int timeval_add_time(struct timeval *result, int sec, int usec);
/* calculate difference between two struct timeval values */
int timeval_subtract(struct timeval *result, struct timeval *x, struct timeval *y)