summary refs log tree commit diff
path: root/iconv
diff options
context:
space:
mode:
Diffstat (limited to 'iconv')
-rw-r--r--iconv/gconv.h4
-rw-r--r--iconv/skeleton.c7
2 files changed, 8 insertions, 3 deletions
diff --git a/iconv/gconv.h b/iconv/gconv.h
index 5717ddbea0..2bba133d0c 100644
--- a/iconv/gconv.h
+++ b/iconv/gconv.h
@@ -87,9 +87,7 @@ typedef int (*__gconv_trans_fct) (struct __gconv_step *step,
 typedef int (*__gconv_trans_context_fct) (struct __gconv_trans_data *data,
 					  __const unsigned char *,
 					  __const unsigned char *,
-					  __const unsigned char *,
-					  unsigned char *, unsigned char *,
-					  unsigned char *);
+					  unsigned char *, unsigned char *);
 
 /* Function to query module about supported encoded character sets.  */
 typedef int (*__gconv_trans_query_fct) (__const char **, size_t *);
diff --git a/iconv/skeleton.c b/iconv/skeleton.c
index dca2c7f7a6..d64d7599b4 100644
--- a/iconv/skeleton.c
+++ b/iconv/skeleton.c
@@ -412,6 +412,13 @@ FUNCTION_NAME (struct __gconv_step *step, struct __gconv_step_data *data,
 	    }
 #endif
 
+	  /* Give the transliteration module the chance to store the
+	     original text and the result in case it needs a context.  */
+	  if (data->__trans.__trans_context_fct != NULL)
+	    DL_CALL_FCT (data->__trans.__trans_context_fct,
+			 (data->__trans.__data, inptr, *inptrp,
+			  outstart, outbuf));
+
 	  /* We finished one use of the loops.  */
 	  ++data->__invocation_counter;