Author: herb
Date: 2006-12-13 21:28:45 +0000 (Wed, 13 Dec 2006)
New Revision: 20159

WebSVN: 
http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=20159

Log:
get rid of defined but not used warning - static function only used
inside the #ifdef HAVE_NATIVE_ICONV

Modified:
   branches/SAMBA_3_0_24/source/lib/iconv.c


Changeset:
Modified: branches/SAMBA_3_0_24/source/lib/iconv.c
===================================================================
--- branches/SAMBA_3_0_24/source/lib/iconv.c    2006-12-13 21:27:45 UTC (rev 
20158)
+++ branches/SAMBA_3_0_24/source/lib/iconv.c    2006-12-13 21:28:45 UTC (rev 
20159)
@@ -128,6 +128,7 @@
        }
 }
 
+#ifdef HAVE_NATIVE_ICONV
 /* if there was an error then reset the internal state,
    this ensures that we don't have a shift state remaining for
    character sets like SJIS */
@@ -135,7 +136,6 @@
                        const char **inbuf, size_t *inbytesleft,
                        char **outbuf, size_t *outbytesleft)
 {
-#ifdef HAVE_NATIVE_ICONV
        size_t ret = iconv((iconv_t)cd, 
                           (char **)inbuf, inbytesleft, 
                           outbuf, outbytesleft);
@@ -145,11 +145,8 @@
                errno = saved_errno;
        }
        return ret;
-#else
-       errno = EINVAL;
-       return -1;
-#endif
 }
+#endif
 
 /**
  * This is a simple portable iconv() implementaion.

Reply via email to