aboutsummaryrefslogtreecommitdiff
path: root/iconv
diff options
context:
space:
mode:
Diffstat (limited to 'iconv')
-rw-r--r--iconv/gconv.c13
-rw-r--r--iconv/gconv_db.c17
-rw-r--r--iconv/gconv_dl.c2
-rw-r--r--iconv/skeleton.c19
4 files changed, 7 insertions, 44 deletions
diff --git a/iconv/gconv.c b/iconv/gconv.c
index ceefffcc87..cc61e03954 100644
--- a/iconv/gconv.c
+++ b/iconv/gconv.c
@@ -23,9 +23,7 @@
#include <gconv.h>
#include <sys/param.h>
-#ifndef STATIC_GCONV
-# include <elf/ldsodefs.h>
-#endif
+#include <ldsodefs.h>
int
internal_function
@@ -43,12 +41,8 @@ __gconv (gconv_t cd, const char **inbuf, const char *inbufend, char **outbuf,
if (inbuf == NULL || *inbuf == NULL)
/* We just flush. */
-#ifdef _CALL_DL_FCT
result = _CALL_DL_FCT (cd->steps->fct,
(cd->steps, cd->data, NULL, NULL, converted, 1));
-#else
- result = cd->steps->fct (cd->steps, cd->data, NULL, NULL, converted, 1);
-#endif
else
{
const char *last_start;
@@ -60,14 +54,9 @@ __gconv (gconv_t cd, const char **inbuf, const char *inbufend, char **outbuf,
do
{
last_start = *inbuf;
-#ifdef _CALL_DL_FCT
result = _CALL_DL_FCT (cd->steps->fct,
(cd->steps, cd->data, inbuf, inbufend,
converted, 0));
-#else
- result = cd->steps->fct (cd->steps, cd->data, inbuf, inbufend,
- converted, 0);
-#endif
}
while (result == GCONV_EMPTY_INPUT && last_start != *inbuf
&& *inbuf + cd->steps->min_needed_from <= inbufend);
diff --git a/iconv/gconv_db.c b/iconv/gconv_db.c
index cbaaf18339..443e5bf878 100644
--- a/iconv/gconv_db.c
+++ b/iconv/gconv_db.c
@@ -23,10 +23,7 @@
#include <string.h>
#include <bits/libc-lock.h>
-#ifndef STATIC_GCONV
-# include <elf/ldsodefs.h>
-#endif
-
+#include <ldsodefs.h>
#include <gconv_int.h>
@@ -158,11 +155,7 @@ free_derivation (void *p)
for (cnt = 0; cnt < deriv->nsteps; ++cnt)
if (deriv->steps[cnt].end_fct)
-#ifdef _CALL_DL_FCT
_CALL_DL_FCT (deriv->steps[cnt].end_fct, (&deriv->steps[cnt]));
-#else
- deriv->steps[cnt].end_fct (&deriv->steps[cnt]);
-#endif
free ((struct gconv_step *) deriv->steps);
free (deriv);
@@ -228,11 +221,7 @@ gen_steps (struct derivation_step *best, const char *toset,
/* Call the init function. */
if (result[step_cnt].init_fct != NULL)
-#ifdef _CALL_DL_FCT
_CALL_DL_FCT (result[step_cnt].init_fct, (&result[step_cnt]));
-#else
- result[step_cnt].init_fct (&result[step_cnt]);
-#endif
current = current->last;
}
@@ -243,11 +232,7 @@ gen_steps (struct derivation_step *best, const char *toset,
while (++step_cnt < *nsteps)
{
if (result[step_cnt].end_fct != NULL)
-#ifdef _CALL_DL_FCT
_CALL_DL_FCT (result[step_cnt].end_fct, (&result[step_cnt]));
-#else
- result[step_cnt].end_fct (&result[step_cnt]);
-#endif
#ifndef STATIC_GCONV
__gconv_release_shlib (result[step_cnt].shlib_handle);
#endif
diff --git a/iconv/gconv_dl.c b/iconv/gconv_dl.c
index 1c04dee169..7c64a912d9 100644
--- a/iconv/gconv_dl.c
+++ b/iconv/gconv_dl.c
@@ -24,9 +24,9 @@
#include <stdlib.h>
#include <string.h>
#include <bits/libc-lock.h>
-#include <elf/ldsodefs.h>
#include <sys/param.h>
+#include <ldsodefs.h>
#include <gconv_int.h>
diff --git a/iconv/skeleton.c b/iconv/skeleton.c
index bae82be3ed..b1e96ebbcb 100644
--- a/iconv/skeleton.c
+++ b/iconv/skeleton.c
@@ -85,8 +85,8 @@
#ifndef STATIC_GCONV
# include <dlfcn.h>
-# include <elf/ldsodefs.h>
#endif
+#include <ldsodefs.h>
/* The direction objects. */
@@ -222,15 +222,9 @@ FUNCTION_NAME (struct gconv_step *step, struct gconv_step_data *data,
if (status == GCONV_OK)
#endif
- {
- /* Give the modules below the same chance. */
-#ifdef DL_CALL_FCT
- status = DL_CALL_FCT (fct, (next_step, next_data, NULL, NULL,
- written, 1));
-#else
- status = (*fct) (next_step, next_data, NULL, NULL, written, 1);
-#endif
- }
+ /* Give the modules below the same chance. */
+ status = DL_CALL_FCT (fct, (next_step, next_data, NULL, NULL,
+ written, 1));
}
}
else
@@ -296,13 +290,8 @@ FUNCTION_NAME (struct gconv_step *step, struct gconv_step_data *data,
const char *outerr = data->outbuf;
int result;
-#ifdef DL_CALL_FCT
result = DL_CALL_FCT (fct, (next_step, next_data, &outerr,
outbuf, written, 0));
-#else
- result = (*fct) (next_step, next_data, &outerr, outbuf,
- written, 0);
-#endif
if (result != GCONV_EMPTY_INPUT)
{