changeset 1719:ac675d98a2c5 trunk

[svn] - remove iconv code altogether
author nenolod
date Sat, 16 Sep 2006 17:47:12 -0700
parents 44c3711dd049
children d8119214066d
files ChangeLog Plugins/Input/wma/libffwma/mms.c
diffstat 2 files changed, 24 insertions(+), 58 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sat Sep 16 17:17:22 2006 -0700
+++ b/ChangeLog	Sat Sep 16 17:47:12 2006 -0700
@@ -1,3 +1,27 @@
+2006-09-17 00:17:22 +0000  Jonathan Schleifer <js@h3c.de>
+  revision [2373]
+  Fixed a LOT of warnings showing up with -Wall. This is the first step
+  towards making Audacious compile with -Wall -Werror, but it's still far
+  from beeing finished.
+  
+  PS: *sigh* I even had to patch C++ (therefore ugly) files!
+  
+
+  Changes:        Modified:
+  +1 -1           trunk/Plugins/Input/aac/src/libmp4.c  
+  +1 -1           trunk/Plugins/Input/console/Audacious_Config.cxx  
+  +1 -1           trunk/Plugins/Input/console/Dual_Resampler.cxx  
+  +2 -0           trunk/Plugins/Input/console/Fir_Resampler.cxx  
+  +2 -2           trunk/Plugins/Input/console/Gb_Apu.cxx  
+  +1 -1           trunk/Plugins/Input/console/Gb_Cpu.h  
+  +1 -1           trunk/Plugins/Input/console/Nes_Cpu.h  
+  +3 -3           trunk/Plugins/Input/console/Nsfe_Emu.cxx  
+  +2 -2           trunk/Plugins/Input/console/Nsfe_Emu.h  
+  +7 -7           trunk/Plugins/Input/cue/cuesheet.c  
+  +1 -1           trunk/Plugins/Input/wma/libffwma/avio.c  
+  +3 -3           trunk/Plugins/Input/wma/libffwma/futils.c  
+
+
 2006-09-16 23:26:54 +0000  Jonathan Schleifer <js@h3c.de>
   revision [2371]
   Fixed a lot of warnings that only showed up on *BSD.
--- a/Plugins/Input/wma/libffwma/mms.c	Sat Sep 16 17:17:22 2006 -0700
+++ b/Plugins/Input/wma/libffwma/mms.c	Sat Sep 16 17:47:12 2006 -0700
@@ -45,13 +45,6 @@
 #include <stdlib.h>
 #include <time.h>
 
-#if defined(HAVE_ICONV) && defined(HAVE_LANGINFO_CODESET)
-#define USE_ICONV
-#include <iconv.h>
-#include <locale.h>
-#include <langinfo.h>
-#endif
-
 /********** logging **********/
 #define LOG_MODULE "mms"
 #define LOG_VERBOSE
@@ -465,44 +458,6 @@
   return 1;
 }
 
-#ifdef USE_ICONV
-static iconv_t string_utf16_open() {
-    return iconv_open("UTF-16LE", nl_langinfo(CODESET));
-}
-
-static void string_utf16_close(iconv_t url_conv) {
-    if (url_conv != (iconv_t)-1) {
-      iconv_close(url_conv);
-    }
-}
-
-static void
-string_utf16(iconv_t url_conv, char *dest, const char *src, int len)
-{
-    memset(dest, 0, 2 * len);
-
-    if (url_conv == (iconv_t)-1) {
-      int i;
-
-      for (i = 0; i < len; i++) {
-        dest[i * 2] = src[i];
-        dest[i * 2 + 1] = 0;
-      }
-      dest[i * 2] = 0;
-      dest[i * 2 + 1] = 0;
-    }
-    else {
-      const char *ip;
-      char *op;
-      size_t len1, len2;
-
-      len1 = len; len2 = 1000;
-      ip = src; op = dest;
-      iconv(url_conv, &ip, &len1, &op, &len2);
-    }
-}
-
-#else
 static void string_utf16(int unused, char *dest, char *src, int len) {
   int i;
 
@@ -516,8 +471,6 @@
   dest[i * 2] = 0;
   dest[i * 2 + 1] = 0;
 }
-#endif
-
 
 /*
  * return packet type
@@ -1030,11 +983,7 @@
  */
 /* FIXME: got somewhat broken during xine_stream_t->(void*) conversion */
 mms_t *mms_connect (mms_io_t *io, void *data, const char *url, int bandwidth) {
-#ifdef USE_ICONV
-  iconv_t url_conv;
-#else
   int     url_conv = 0;
-#endif
   mms_t  *this;
   int     res;
   GURI   *uri;
@@ -1090,9 +1039,6 @@
   /* FIXME de-xine-ification */
 /*   report_progress (stream, 30); */
   
-#ifdef USE_ICONV
-  url_conv = string_utf16_open();
-#endif
   /*
    * let the negotiations begin...
    */
@@ -1269,10 +1215,6 @@
 
 /*   report_progress (stream, 100); */
 
-#ifdef USE_ICONV
-  string_utf16_close(url_conv);
-#endif
-
   lprintf("mms_connect: passed\n" );
  
   return this;