From: Sven Verdoolaege <skimo@kotnet.org>
Date: Wed, 30 Dec 2009 08:36:11 +0100
Subject: [PATCH] common/conv.c: fix segmentation fault during conversion on
 64bit machines

The second argument of iconv is of type size_t * and not of type int *.
---
 common/conv.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/common/conv.c b/common/conv.c
index 02dfd32b..9884a634 100644
--- a/common/conv.c
+++ b/common/conv.c
@@ -89,7 +89,7 @@ int
 default_char2int(SCR *sp, const char * str, ssize_t len, CONVWIN *cw, 
 		size_t *tolen, CHAR_T **dst, char *enc)
 {
-    int i = 0, j;
+    size_t i = 0, j;
     CHAR_T **tostr = (CHAR_T **)&cw->bp1;
     size_t  *blen = &cw->blen1;
     mbstate_t mbs;
@@ -210,7 +210,7 @@ int
 default_int2char(SCR *sp, const CHAR_T * str, ssize_t len, CONVWIN *cw, 
 		size_t *tolen, char **pdst, char *enc)
 {
-    int i, j, offset = 0;
+    size_t i, j, offset = 0;
     char **tostr = (char **)&cw->bp1;
     size_t  *blen = &cw->blen1;
     mbstate_t mbs;
-- 
2.37.2

