]> git.ipfire.org Git - thirdparty/cups.git/blobdiff - cups/transcode.c
Load cups into easysw/current.
[thirdparty/cups.git] / cups / transcode.c
index f21ab22e6a919cdcd3ae5a54d277da469e086eb1..b0b5166fcce7d05c3e347d5d3a3659acf12a37f8 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id$"
+ * "$Id: transcode.c 6038 2006-10-14 15:53:10Z mike $"
  *
  *   Transcoding support for the Common UNIX Printing System (CUPS).
  *
@@ -408,7 +408,6 @@ cupsUTF8ToUTF32(
     const cups_utf8_t *src,            /* I - Source string */
     const int         maxout)          /* I - Max output */
 {
-  size_t       srclen;                 /* Source string length */
   int          i;                      /* Looping variable */
   cups_utf8_t  ch;                     /* Character value */
   cups_utf8_t  next;                   /* Next character value */
@@ -430,7 +429,6 @@ cupsUTF8ToUTF32(
   */
 
   *dest++ = 0xfeff;
-  srclen  = strlen((char *)src);
 
   for (i = maxout - 1; *src && i > 0; i --)
   {
@@ -447,6 +445,7 @@ cupsUTF8ToUTF32(
       */
 
       *dest++ = ch;
+      continue;
     }
     else if ((ch & 0xe0) == 0xc0)
     {
@@ -542,7 +541,7 @@ cupsUTF8ToUTF32(
     * Check for UTF-16 surrogate (illegal UTF-8)...
     */
 
-    if (*dest >= 0xd800 && *dest <= 0xdfff)
+    if (ch32 >= 0xd800 && ch32 <= 0xdfff)
       return (-1);
   }
 
@@ -1142,7 +1141,7 @@ free_vbcs_charmap(_cups_vmap_t *vmap)     /* I - Character set */
  */
 
 
-void *                                 /* O - Charset map pointer */
+static void *                          /* O - Charset map pointer */
 get_charmap(
     const cups_encoding_t encoding)    /* I - Encoding */
 {
@@ -1585,5 +1584,5 @@ get_vbcs_charmap(
 
 
 /*
- * End of "$Id$"
+ * End of "$Id: transcode.c 6038 2006-10-14 15:53:10Z mike $"
  */