linux: DtHelp/StringFuncs, enable real iconv() support
authorJon Trulson <jon@radscan.com>
Mon, 5 Nov 2018 22:33:16 +0000 (15:33 -0700)
committerJon Trulson <jon@radscan.com>
Mon, 5 Nov 2018 22:33:16 +0000 (15:33 -0700)
For some reason, the #include of iconv.h was removed, and dummy stubs
were put in place on linux systems (only).  This caused iconv() calls
to be completely ignored.

Now we use iconv() just like very other OS we support.

cde/lib/DtHelp/StringFuncs.c

index 8d12e43250f20f5e8e4f20d7aa572faa3a6b6c25..a343e37d6353670ffb8009edef7e43a78d3128e1 100644 (file)
 #include <errno.h>
 #include <locale.h>  /* getlocale(), LOCALE_STATUS, LC_xxx */
 
-#if defined(_AIX) || defined(CSRG_BASED)
+#if defined(_AIX) || defined(CSRG_BASED) || defined(__linux__)
 #include <ctype.h>
 #endif
 
 #include "CvStringI.h"        /* for string functions used by Canvas Engine */
 #include "StringFuncsI.h"     /* for _CEStrcollProc */
 
-#if !defined(__linux__)
-# include <iconv.h>
-#else
+/* JET: This was if !defined(linux), which is wrong.  We should use the
+ * real deal on linux too */
+
+#include <iconv.h>
+
+#if 0
 # define iconv_t               int
 # define iconv_open(a, b)      ((iconv_t) -1)
 # define iconv(a, b, c, d, e)  ((size_t) 0)