summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzwelch <zwelch@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2009-05-12 08:35:17 +0000
committerzwelch <zwelch@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2009-05-12 08:35:17 +0000
commitf976af56a4352d0406b930528beec105df13cacb (patch)
tree5d0f865332cdc9ec4e6db5d26f3f9faf56f0926c
parent513627092034136d9d7516b41d8ef3c8881d1950 (diff)
downloadopenocd+libswd-f976af56a4352d0406b930528beec105df13cacb.tar.gz
openocd+libswd-f976af56a4352d0406b930528beec105df13cacb.tar.bz2
openocd+libswd-f976af56a4352d0406b930528beec105df13cacb.tar.xz
openocd+libswd-f976af56a4352d0406b930528beec105df13cacb.zip
Audit and remove redundant uses of replacements.h in the tree.
git-svn-id: svn://svn.berlios.de/openocd/trunk@1761 b42882b7-edfa-0310-969c-e2dbd0fdcd60
-rw-r--r--src/helper/fileio.h4
-rw-r--r--src/helper/jim-eventloop.c5
-rw-r--r--src/helper/jim.c2
-rw-r--r--src/helper/log.h1
-rw-r--r--src/helper/replacements.c16
-rw-r--r--src/helper/replacements.h2
-rw-r--r--src/target/algorithm.c1
-rw-r--r--src/target/target.h2
8 files changed, 8 insertions, 25 deletions
diff --git a/src/helper/fileio.h b/src/helper/fileio.h
index 36e749b2..e62f0ba8 100644
--- a/src/helper/fileio.h
+++ b/src/helper/fileio.h
@@ -26,9 +26,9 @@
#ifndef FILEIO_H
#define FILEIO_H
-#define FILEIO_MAX_ERROR_STRING (128)
+#include "types.h"
-#include "replacements.h"
+#define FILEIO_MAX_ERROR_STRING (128)
enum fileio_type
{
diff --git a/src/helper/jim-eventloop.c b/src/helper/jim-eventloop.c
index d53a76db..7524d39f 100644
--- a/src/helper/jim-eventloop.c
+++ b/src/helper/jim-eventloop.c
@@ -61,11 +61,6 @@
#include "jim-eventloop.h"
#endif
-#include "replacements.h"
-
-
-/* --- */
-
/* File event structure */
typedef struct Jim_FileEvent {
void *handle;
diff --git a/src/helper/jim.c b/src/helper/jim.c
index e344ef59..261b8602 100644
--- a/src/helper/jim.c
+++ b/src/helper/jim.c
@@ -56,8 +56,6 @@
#include <stdarg.h>
#include <limits.h>
-#include "replacements.h"
-
/* Include the platform dependent libraries for
* dynamic loading of libraries. */
#ifdef JIM_DYNLIB
diff --git a/src/helper/log.h b/src/helper/log.h
index 4f781991..1a032b26 100644
--- a/src/helper/log.h
+++ b/src/helper/log.h
@@ -26,7 +26,6 @@
#ifndef ERROR_H
#define ERROR_H
-#include "replacements.h"
#include "command.h"
/* logging priorities
diff --git a/src/helper/replacements.c b/src/helper/replacements.c
index cc0c242a..6b367fa8 100644
--- a/src/helper/replacements.c
+++ b/src/helper/replacements.c
@@ -23,17 +23,10 @@
* Free Software Foundation, Inc., *
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
***************************************************************************/
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
/* DANGER!!!! These must be defined *BEFORE* replacements.h and the malloc() macro!!!! */
#include <stdlib.h>
#include <string.h>
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
/*
* clear_malloc
*
@@ -65,9 +58,12 @@ void *fill_malloc(size_t size)
}
#define IN_REPLACEMENTS_C
-#include "replacements.h"
-
-#include <stdio.h>
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+#ifdef HAVE_STRINGS_H
+#include <strings.h>
+#endif
#ifdef _WIN32
#include <io.h>
diff --git a/src/helper/replacements.h b/src/helper/replacements.h
index 34e5daa4..7ecbbb22 100644
--- a/src/helper/replacements.h
+++ b/src/helper/replacements.h
@@ -26,8 +26,6 @@
#ifndef REPLACEMENTS_H
#define REPLACEMENTS_H
-#include "types.h"
-
/* MIN,MAX macros */
#ifndef MIN
#define MIN(a,b) (((a)<(b))?(a):(b))
diff --git a/src/target/algorithm.c b/src/target/algorithm.c
index a3672b20..664aeb27 100644
--- a/src/target/algorithm.c
+++ b/src/target/algorithm.c
@@ -22,7 +22,6 @@
#endif
#include "algorithm.h"
-#include "replacements.h"
#include "binarybuffer.h"
diff --git a/src/target/target.h b/src/target/target.h
index a664dc34..4a6dde1a 100644
--- a/src/target/target.h
+++ b/src/target/target.h
@@ -30,8 +30,6 @@
#include "algorithm.h"
#include "command.h"
-#include "replacements.h"
-
struct reg_s;
struct trace_s;
struct command_context_s;