]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Mirror 1.1.x changes.
authormike <mike@7a7537e8-13f0-0310-91df-b6672ffda945>
Wed, 25 Feb 2004 20:01:37 +0000 (20:01 +0000)
committermike <mike@7a7537e8-13f0-0310-91df-b6672ffda945>
Wed, 25 Feb 2004 20:01:37 +0000 (20:01 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.2@4086 7a7537e8-13f0-0310-91df-b6672ffda945

27 files changed:
backend/lpd.c
cgi-bin/admin.c
cgi-bin/ipp-var.c
cgi-bin/template.c
cgi-bin/var.c
filter/form-tree.c
filter/hpgl-input.c
filter/image-pnm.c
filter/image.c
filter/imagetoraster.c
filter/pstops.c
filter/textcommon.c
filter/texttops.c
pdftops/parseargs.c
scheduler/classes.c
scheduler/client.c
scheduler/conf.c
scheduler/cups-lpd.c
scheduler/devices.c
scheduler/dirsvc.c
scheduler/ipp.c
scheduler/job.c
scheduler/mime.c
scheduler/ppds.c
scheduler/printers.c
scheduler/type.c
systemv/cupstestppd.c

index ddee27596645aa39257f01c1cc3a9c28609eebb3..22ea395f6ef0da269f1b856097a86ca5a3b4b688 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: lpd.c,v 1.28.2.29 2004/02/24 21:51:36 mike Exp $"
+ * "$Id: lpd.c,v 1.28.2.30 2004/02/25 20:01:36 mike Exp $"
  *
  *   Line Printer Daemon backend for the Common UNIX Printing System (CUPS).
  *
@@ -392,7 +392,7 @@ main(int  argc,                             /* I - Number of command-line arguments (6 or 7) */
     */
 
     for (ptr = title; *ptr; ptr ++)
-      if (!isalnum(*ptr) && !isspace(*ptr))
+      if (!isalnum(*ptr & 255) && !isspace(*ptr & 255))
        *ptr = '_';
   }
 
@@ -1028,5 +1028,5 @@ sigterm_handler(int sig)          /* I - Signal */
 
 
 /*
- * End of "$Id: lpd.c,v 1.28.2.29 2004/02/24 21:51:36 mike Exp $".
+ * End of "$Id: lpd.c,v 1.28.2.30 2004/02/25 20:01:36 mike Exp $".
  */
index 1384e5e47e527d04dd7149ad9c7a393f0b7f64b0..f32788d792296667356175775b1e7031d7970f13 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: admin.c,v 1.22.2.25 2003/09/30 15:14:17 mike Exp $"
+ * "$Id: admin.c,v 1.22.2.26 2004/02/25 20:01:37 mike Exp $"
  *
  *   Administration CGI for the Common UNIX Printing System (CUPS).
  *
@@ -1234,7 +1234,7 @@ do_config_printer(http_t      *http,      /* I - HTTP connection */
         strlcpy(keyword, line + 8, sizeof(keyword));
 
        for (keyptr = keyword; *keyptr; keyptr ++)
-         if (*keyptr == ':' || isspace(*keyptr))
+         if (*keyptr == ':' || isspace(*keyptr & 255))
            break;
 
         *keyptr = '\0';
@@ -1597,5 +1597,5 @@ get_line(char *buf,       /* I - Line buffer */
 
 
 /*
- * End of "$Id: admin.c,v 1.22.2.25 2003/09/30 15:14:17 mike Exp $".
+ * End of "$Id: admin.c,v 1.22.2.26 2004/02/25 20:01:37 mike Exp $".
  */
index 0065e2e9c9620f3ff53ea205ad0f7e7d4e810dc0..d2b0f2ec58c2c511871c4335a5cbfcee10375d6e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: ipp-var.c,v 1.23.2.18 2004/02/24 16:38:17 mike Exp $"
+ * "$Id: ipp-var.c,v 1.23.2.19 2004/02/25 20:01:37 mike Exp $"
  *
  *   IPP variable routines for the Common UNIX Printing System (CUPS).
  *
@@ -67,7 +67,7 @@ ippGetAttributes(ipp_t      *request, /* I - IPP request */
   if (lang != NULL)
   {
     for (i = 0; lang[i] && i < 15; i ++)
-      if (isalnum(lang[i]))
+      if (isalnum(lang[i] & 255))
         locale[i] = tolower(lang[i]);
       else
         locale[i] = '_';
@@ -546,5 +546,5 @@ ippSetCGIVars(ipp_t      *response, /* I - Response data to be copied... */
 
 
 /*
- * End of "$Id: ipp-var.c,v 1.23.2.18 2004/02/24 16:38:17 mike Exp $".
+ * End of "$Id: ipp-var.c,v 1.23.2.19 2004/02/25 20:01:37 mike Exp $".
  */
index 3f9e14a2640bc2c3cae57562196c8dcbb9b0ef0f..0d97249e7a5e8bb962dfacaa0973bf00a677d095 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: template.c,v 1.22.2.5 2003/07/20 15:41:18 mike Exp $"
+ * "$Id: template.c,v 1.22.2.6 2004/02/25 20:01:37 mike Exp $"
  *
  *   CGI template function.
  *
@@ -96,7 +96,7 @@ cgiCopyTemplateLang(FILE       *out,          /* I - Output file */
   if (lang != NULL)
   {
     for (i = 0; lang[i] && i < 15; i ++)
-      if (isalnum(lang[i]))
+      if (isalnum(lang[i] & 255))
         locale[i] = tolower(lang[i]);
       else
         locale[i] = '_';
@@ -189,7 +189,7 @@ cgi_copy(FILE *out,         /* I - Output file */
 
       *s = '\0';
 
-      if (s == name && isspace(ch))
+      if (s == name && isspace(ch & 255))
       {
         if (out)
        {
@@ -210,7 +210,7 @@ cgi_copy(FILE *out,         /* I - Output file */
         * Insert value only if it exists...
        */
 
-       if ((nameptr = strrchr(name, '-')) != NULL && isdigit(nameptr[1]))
+       if ((nameptr = strrchr(name, '-')) != NULL && isdigit(nameptr[1] & 255))
        {
          *nameptr++ = '\0';
 
@@ -254,7 +254,7 @@ cgi_copy(FILE *out,         /* I - Output file */
        int  count;     /* Number of elements */
 
 
-        if (isdigit(name[1]))
+        if (isdigit(name[1] & 255))
          count = atoi(name + 1);
        else
           count = cgiGetSize(name + 1);
@@ -280,7 +280,7 @@ cgi_copy(FILE *out,         /* I - Output file */
         * Insert variable or variable name (if element is NULL)...
        */
 
-       if ((nameptr = strrchr(name, '-')) != NULL && isdigit(nameptr[1]))
+       if ((nameptr = strrchr(name, '-')) != NULL && isdigit(nameptr[1] & 255))
        {
          *nameptr++ = '\0';
          if ((value = cgiGetArray(name, atoi(nameptr) - 1)) == NULL)
@@ -367,7 +367,7 @@ cgi_copy(FILE *out,         /* I - Output file */
             if (innername[0] == '#')
              sprintf(s, "%d", cgiGetSize(innername + 1));
            else if ((innerptr = strrchr(innername, '-')) != NULL &&
-                    isdigit(innerptr[1]))
+                    isdigit(innerptr[1] & 255))
             {
              *innerptr++ = '\0';
              if ((innerval = cgiGetArray(innername, atoi(innerptr) - 1)) == NULL)
@@ -488,5 +488,5 @@ cgi_puts(const char *s,
 
 
 /*
- * End of "$Id: template.c,v 1.22.2.5 2003/07/20 15:41:18 mike Exp $".
+ * End of "$Id: template.c,v 1.22.2.6 2004/02/25 20:01:37 mike Exp $".
  */
index eeae98c739d3e5d7136a544e414cebffaff651f7..e288affbecb40674aaa4cde86ff72229c3213b37 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: var.c,v 1.20.2.3 2003/01/07 18:26:20 mike Exp $"
+ * "$Id: var.c,v 1.20.2.4 2004/02/25 20:01:37 mike Exp $"
  *
  *   CGI form variable and array functions.
  *
@@ -622,7 +622,7 @@ cgi_initialize_string(const char *data)     /* I - Form data string */
     * Add the string to the variable "database"...
     */
 
-    if ((s = strrchr(name, '-')) != NULL && isdigit(s[1]))
+    if ((s = strrchr(name, '-')) != NULL && isdigit(s[1] & 255))
     {
       *s++ = '\0';
       if (value[0])
@@ -668,5 +668,5 @@ cgi_sort_variables(void)
 
 
 /*
- * End of "$Id: var.c,v 1.20.2.3 2003/01/07 18:26:20 mike Exp $".
+ * End of "$Id: var.c,v 1.20.2.4 2004/02/25 20:01:37 mike Exp $".
  */
index 0323a3d5e06b5310835d9138ae143581249c0b8e..dc6673de11baee4566ad847c0cb7c4b4f2cd2654 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: form-tree.c,v 1.4.2.3 2003/01/07 18:26:51 mike Exp $"
+ * "$Id: form-tree.c,v 1.4.2.4 2004/02/25 20:01:37 mike Exp $"
  *
  *   CUPS form document tree routines for the Common UNIX Printing
  *   System (CUPS).
@@ -202,7 +202,7 @@ formRead(FILE   *fp,                        /* I - File to read from */
 
     if (p == NULL || !p->preformatted)
     {
-      while (isspace(ch))
+      while (isspace(ch & 255))
       {
         have_whitespace = 1;
         ch              = getc(fp);
@@ -288,7 +288,7 @@ formRead(FILE   *fp,                        /* I - File to read from */
           for (glyphptr = glyph;
                (ch = getc(fp)) != EOF && (glyphptr - glyph) < 15;
                glyphptr ++)
-            if (!isalnum(ch))
+            if (!isalnum(ch & 255))
               break;
             else
               *glyphptr = ch;
@@ -335,14 +335,14 @@ formRead(FILE   *fp,                      /* I - File to read from */
       if (have_whitespace)
         *ptr++ = ' ';
 
-      while (!isspace(ch) && ch != '<' && ch != EOF && ptr < (s + sizeof(s) - 1))
+      while (!isspace(ch & 255) && ch != '<' && ch != EOF && ptr < (s + sizeof(s) - 1))
       {
         if (ch == '&')
         {
           for (glyphptr = glyph;
                (ch = getc(fp)) != EOF && (glyphptr - glyph) < 15;
                glyphptr ++)
-            if (!isalnum(ch))
+            if (!isalnum(ch & 255))
               break;
             else
               *glyphptr = ch;
@@ -368,7 +368,7 @@ formRead(FILE   *fp,                        /* I - File to read from */
         ch = getc(fp);
       }
 
-      if (isspace(ch))
+      if (isspace(ch & 255))
         *ptr++ = ' ';
 
       *ptr = '\0';
@@ -468,7 +468,7 @@ parse_attr(tree_t *t,                       /* I - Current tree node */
 
   ptr = name;
   while ((ch = getc(fp)) != EOF)
-    if (isalnum(ch))
+    if (isalnum(ch & 255))
     {
       if (ptr < (name + sizeof(name) - 1))
         *ptr++ = ch;
@@ -478,7 +478,7 @@ parse_attr(tree_t *t,                       /* I - Current tree node */
 
   *ptr = '\0';
 
-  while (isspace(ch) || ch == '\r')
+  while (isspace(ch & 255) || ch == '\r')
     ch = getc(fp);
 
   switch (ch)
@@ -492,7 +492,7 @@ parse_attr(tree_t *t,                       /* I - Current tree node */
         ptr = value;
         ch  = getc(fp);
 
-        while (isspace(ch) || ch == '\r')
+        while (isspace(ch & 255) || ch == '\r')
           ch = getc(fp);
 
         if (ch == EOF)
@@ -522,7 +522,7 @@ parse_attr(tree_t *t,                       /* I - Current tree node */
         {
           *ptr++ = ch;
           while ((ch = getc(fp)) != EOF)
-            if (isspace(ch) || ch == '>' || ch == '/' || ch == '\r')
+            if (isspace(ch & 255) || ch == '>' || ch == '/' || ch == '\r')
               break;
             else if (ptr < (value + sizeof(value) - 1))
               *ptr++ = ch;
@@ -556,7 +556,7 @@ parse_element(tree_t *t,            /* I - Current tree node */
   eptr = element;
 
   while ((ch = getc(fp)) != EOF && eptr < (element + sizeof(element) - 1))
-    if (ch == '>' || ch == '/' || isspace(ch))
+    if (ch == '>' || ch == '/' || isspace(ch & 255))
       break;
     else
       *eptr++ = ch;
@@ -602,7 +602,7 @@ parse_element(tree_t *t,            /* I - Current tree node */
   {
     while (ch != EOF && ch != '>' && ch != '/')
     {
-      if (!isspace(ch))
+      if (!isspace(ch & 255))
       {
         ungetc(ch, fp);
         parse_variable(t, fp);
@@ -620,5 +620,5 @@ parse_element(tree_t *t,            /* I - Current tree node */
 
 
 /*
- * End of "$Id: form-tree.c,v 1.4.2.3 2003/01/07 18:26:51 mike Exp $".
+ * End of "$Id: form-tree.c,v 1.4.2.4 2004/02/25 20:01:37 mike Exp $".
  */
index a8e7665df9ae3d23b55a5c892a631d37a02ec0db..83c327aa142a83aa5c42f996b6241ddb62f3ddd6 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: hpgl-input.c,v 1.10.2.4 2003/11/07 21:43:36 mike Exp $"
+ * "$Id: hpgl-input.c,v 1.10.2.5 2004/02/25 20:01:37 mike Exp $"
  *
  *   HP-GL/2 input processing for the Common UNIX Printing System (CUPS).
  *
@@ -117,7 +117,7 @@ ParseCommand(FILE    *fp,   /* I - File to read from */
            }
 
         default : /* HP RTL/PCL control */
-            while ((i = getc(fp)) != EOF && !isupper(i));
+            while ((i = getc(fp)) != EOF && !isupper(i & 255));
             break;
       }
   } while (ch < ' ');
@@ -243,5 +243,5 @@ FreeParameters(int     num_params,  /* I - Number of parameters */
 
 
 /*
- * End of "$Id: hpgl-input.c,v 1.10.2.4 2003/11/07 21:43:36 mike Exp $".
+ * End of "$Id: hpgl-input.c,v 1.10.2.5 2004/02/25 20:01:37 mike Exp $".
  */
index 77f7120672cd9c0982d0ab51df7c2f903aaf6ca6..933ae3165a3cc9584eb1a78e0eaf064e92f44fbe 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: image-pnm.c,v 1.7.2.5 2003/01/07 18:26:54 mike Exp $"
+ * "$Id: image-pnm.c,v 1.7.2.6 2004/02/25 20:01:37 mike Exp $"
  *
  *   Portable Any Map file routines for the Common UNIX Printing System (CUPS).
  *
@@ -80,17 +80,17 @@ ImageReadPNM(image_t    *img,               /* IO - Image */
   lineptr ++;
 
   format = atoi(lineptr);
-  while (isdigit(*lineptr))
+  while (isdigit(*lineptr & 255))
     lineptr ++;
 
   while (lineptr != NULL && img->xsize == 0)
   {
     if (*lineptr == '\0' || *lineptr == '#')
       lineptr = fgets(line, sizeof(line), fp);
-    else if (isdigit(*lineptr))
+    else if (isdigit(*lineptr & 255))
     {
       img->xsize = atoi(lineptr);
-      while (isdigit(*lineptr))
+      while (isdigit(*lineptr & 255))
        lineptr ++;
     }
     else
@@ -101,10 +101,10 @@ ImageReadPNM(image_t    *img,             /* IO - Image */
   {
     if (*lineptr == '\0' || *lineptr == '#')
       lineptr = fgets(line, sizeof(line), fp);
-    else if (isdigit(*lineptr))
+    else if (isdigit(*lineptr & 255))
     {
       img->ysize = atoi(lineptr);
-      while (isdigit(*lineptr))
+      while (isdigit(*lineptr & 255))
        lineptr ++;
     }
     else
@@ -119,10 +119,10 @@ ImageReadPNM(image_t    *img,             /* IO - Image */
     {
       if (*lineptr == '\0' || *lineptr == '#')
        lineptr = fgets(line, sizeof(line), fp);
-      else if (isdigit(*lineptr))
+      else if (isdigit(*lineptr & 255))
       {
        maxval = atoi(lineptr);
-       while (isdigit(*lineptr))
+       while (isdigit(*lineptr & 255))
          lineptr ++;
       }
       else
@@ -302,5 +302,5 @@ ImageReadPNM(image_t    *img,               /* IO - Image */
 
 
 /*
- * End of "$Id: image-pnm.c,v 1.7.2.5 2003/01/07 18:26:54 mike Exp $".
+ * End of "$Id: image-pnm.c,v 1.7.2.6 2004/02/25 20:01:37 mike Exp $".
  */
index 477b3997b259a184e2a1176921f89d6a03312ef3..d705731cfe3f986e34694d15e8ce2e4deaa3da04 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: image.c,v 1.28.2.4 2003/01/07 18:26:56 mike Exp $"
+ * "$Id: image.c,v 1.28.2.5 2004/02/25 20:01:37 mike Exp $"
  *
  *   Base image support for the Common UNIX Printing System (CUPS).
  *
@@ -277,13 +277,13 @@ ImageSetMaxTiles(image_t *img,            /* I - Image to set */
           max_size *= 4 * TILE_SIZE * TILE_SIZE;
          break;
       case 2 :
-          if (tolower(cache_units[0]) == 'g')
+          if (tolower(cache_units[0] & 255) == 'g')
            max_size *= 1024 * 1024 * 1024;
-          else if (tolower(cache_units[0]) == 'm')
+          else if (tolower(cache_units[0] & 255) == 'm')
            max_size *= 1024 * 1024;
-         else if (tolower(cache_units[0]) == 'k')
+         else if (tolower(cache_units[0] & 255) == 'k')
            max_size *= 1024;
-         else if (tolower(cache_units[0]) == 't')
+         else if (tolower(cache_units[0] & 255) == 't')
            max_size *= 4 * TILE_SIZE * TILE_SIZE;
          break;
     }
@@ -771,5 +771,5 @@ flush_tile(image_t *img)    /* I - Image */
 
 
 /*
- * End of "$Id: image.c,v 1.28.2.4 2003/01/07 18:26:56 mike Exp $".
+ * End of "$Id: image.c,v 1.28.2.5 2004/02/25 20:01:37 mike Exp $".
  */
index b0ef327b141d03f14a244062a790940d80c590d1..6a52f31ddf8e89bfcd0eb33f7fe6999fadb9435a 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: imagetoraster.c,v 1.56.2.16 2003/07/28 17:32:38 mike Exp $"
+ * "$Id: imagetoraster.c,v 1.56.2.17 2004/02/25 20:01:37 mike Exp $"
  *
  *   Image file to raster filter for the Common UNIX Printing System (CUPS).
  *
@@ -1479,7 +1479,7 @@ exec_code(cups_page_header2_t *header,    /* I - Page header */
     */
 
     code ++;
-    for (ptr = name; isalnum(*code) && (ptr - name) < (sizeof(name) - 1);)
+    for (ptr = name; isalnum(*code & 255) && (ptr - name) < (sizeof(name) - 1);)
       *ptr++ = *code++;
     *ptr = '\0';
 
@@ -1487,7 +1487,7 @@ exec_code(cups_page_header2_t *header,    /* I - Page header */
     * The parse the value as needed...
     */
 
-    while (isspace(*code))
+    while (isspace(*code & 255))
       code ++;
 
     if (*code == '\0')
@@ -1519,7 +1519,7 @@ exec_code(cups_page_header2_t *header,    /* I - Page header */
         if (*code == '\\')
        {
          code ++;
-         if (isdigit(*code))
+         if (isdigit(*code & 255))
            *ptr++ = (char)strtol(code, (char **)&code, 8);
           else
            *ptr++ = *code++;
@@ -1529,14 +1529,14 @@ exec_code(cups_page_header2_t *header,  /* I - Page header */
 
       *ptr = '\0';
     }
-    else if (isdigit(*code) || *code == '-')
+    else if (isdigit(*code & 255) || *code == '-')
     {
      /*
       * Read single number...
       */
 
       for (ptr = value;
-           (isdigit(*code) || *code == '-') &&
+           (isdigit(*code & 255) || *code == '-') &&
               (ptr - value) < (sizeof(value) - 1);)
        *ptr++ = *code++;
       *ptr = '\0';
@@ -1548,7 +1548,7 @@ exec_code(cups_page_header2_t *header,    /* I - Page header */
       */
 
       for (ptr = value;
-           (isalnum(*code) || *code == '_') &&
+           (isalnum(*code & 255) || *code == '_') &&
               (ptr - value) < (sizeof(value) - 1);)
        *ptr++ = *code++;
       *ptr = '\0';
@@ -4594,5 +4594,5 @@ make_lut(ib_t  *lut,              /* I - Lookup table */
 
 
 /*
- * End of "$Id: imagetoraster.c,v 1.56.2.16 2003/07/28 17:32:38 mike Exp $".
+ * End of "$Id: imagetoraster.c,v 1.56.2.17 2004/02/25 20:01:37 mike Exp $".
  */
index b94e8fde7d97e467c6db675173d51d7db93efa99..c6aa299eade345b418bb33444d7cc6bc64b54dd4 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: pstops.c,v 1.54.2.47 2004/02/24 20:16:42 mike Exp $"
+ * "$Id: pstops.c,v 1.54.2.48 2004/02/25 20:01:37 mike Exp $"
  *
  *   PostScript filter for the Common UNIX Printing System (CUPS).
  *
@@ -1131,7 +1131,7 @@ check_range(int page)     /* I - Page number */
       if (*range == '-')
       {
         range ++;
-       if (!isdigit(*range))
+       if (!isdigit(*range & 255))
          upper = 65535;
        else
          upper = strtol(range, (char **)&range, 10);
@@ -1892,5 +1892,5 @@ start_nup(int number,                     /* I - Page number */
 
 
 /*
- * End of "$Id: pstops.c,v 1.54.2.47 2004/02/24 20:16:42 mike Exp $".
+ * End of "$Id: pstops.c,v 1.54.2.48 2004/02/25 20:01:37 mike Exp $".
  */
index eac0e9932ed8eb056f217374b29db7bd8f9b9c20..4e678652b25eee135c1830df53118264adc6f6e2 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: textcommon.c,v 1.16.2.13 2003/08/28 14:36:54 mike Exp $"
+ * "$Id: textcommon.c,v 1.16.2.14 2004/02/25 20:01:37 mike Exp $"
  *
  *   Common text filter routines for the Common UNIX Printing System (CUPS).
  *
@@ -888,7 +888,7 @@ TextMain(const char *name,  /* I - Name of filter */
 
              attr &= ~ATTR_BOLD;
            }
-           else if (!(isalnum(ch) || ch == '_') && keyptr > keyword)
+           else if (!(isalnum(ch & 255) || ch == '_') && keyptr > keyword)
            {
             /*
              * Look for a keyword...
@@ -914,7 +914,7 @@ TextMain(const char *name,  /* I - Name of filter */
                }
              }
            }
-           else if ((isalnum(ch) || ch == '_') && !ccomment && !cstring)
+           else if ((isalnum(ch & 255) || ch == '_') && !ccomment && !cstring)
            {
             /*
              * Add characters to the current keyword (if they'll fit).
@@ -1182,5 +1182,5 @@ getutf8(FILE *fp) /* I - File to read from */
 
 
 /*
- * End of "$Id: textcommon.c,v 1.16.2.13 2003/08/28 14:36:54 mike Exp $".
+ * End of "$Id: textcommon.c,v 1.16.2.14 2004/02/25 20:01:37 mike Exp $".
  */
index 05db844d0e9275095dbacac5e494b7900b8414b1..72fd4a879afe22d73309a45d01f412675934e8d1 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: texttops.c,v 1.34.2.12 2003/01/07 18:27:01 mike Exp $"
+ * "$Id: texttops.c,v 1.34.2.13 2004/02/25 20:01:37 mike Exp $"
  *
  *   Text to PostScript filter for the Common UNIX Printing System (CUPS).
  *
@@ -294,7 +294,7 @@ WriteProlog(const char *title,              /* I - Title of job */
     */
 
     line[strlen(line) - 1] = '\0'; /* Drop \n */
-    for (lineptr = line + 7; isspace(*lineptr); lineptr ++); /* Skip whitespace */
+    for (lineptr = line + 7; isspace(*lineptr & 255); lineptr ++); /* Skip whitespace */
 
     if (strcmp(lineptr, "8bit") == 0)
     {
@@ -329,7 +329,7 @@ WriteProlog(const char *title,              /* I - Title of job */
         start = strtol(lineptr, &lineptr, 16);
        end   = strtol(lineptr, &lineptr, 16);
 
-       while (isspace(*lineptr))
+       while (isspace(*lineptr & 255))
          lineptr ++;
 
         if (!*lineptr)
@@ -337,7 +337,7 @@ WriteProlog(const char *title,              /* I - Title of job */
 
        valptr = lineptr;
 
-       while (!isspace(*lineptr) && *lineptr)
+       while (!isspace(*lineptr & 255) && *lineptr)
          lineptr ++;
 
        if (!*lineptr)
@@ -368,12 +368,12 @@ WriteProlog(const char *title,            /* I - Title of job */
        * Got the direction, now get the width...
        */
 
-       while (isspace(*lineptr))
+       while (isspace(*lineptr & 255))
          lineptr ++;
 
        valptr = lineptr;
 
-       while (!isspace(*lineptr) && *lineptr)
+       while (!isspace(*lineptr & 255) && *lineptr)
          lineptr ++;
 
        if (!*lineptr)
@@ -406,12 +406,12 @@ WriteProlog(const char *title,            /* I - Title of job */
 
        for (i = 0; *lineptr && i < 4; i ++)
        {
-         while (isspace(*lineptr))
+         while (isspace(*lineptr & 255))
            lineptr ++;
 
          valptr = lineptr;
 
-         while (!isspace(*lineptr) && *lineptr)
+         while (!isspace(*lineptr & 255) && *lineptr)
            lineptr ++;
 
           if (*lineptr)
@@ -496,12 +496,12 @@ WriteProlog(const char *title,            /* I - Title of job */
         start = strtol(lineptr, &lineptr, 16);
        end   = strtol(lineptr, &lineptr, 16);
 
-       while (isspace(*lineptr))
+       while (isspace(*lineptr & 255))
          lineptr ++;
 
        valptr = lineptr;
 
-       while (!isspace(*lineptr) && *lineptr)
+       while (!isspace(*lineptr & 255) && *lineptr)
          lineptr ++;
 
        if (!*lineptr)
@@ -532,12 +532,12 @@ WriteProlog(const char *title,            /* I - Title of job */
        * Got the direction, now get the width...
        */
 
-       while (isspace(*lineptr))
+       while (isspace(*lineptr & 255))
          lineptr ++;
 
        valptr = lineptr;
 
-       while (!isspace(*lineptr) && *lineptr)
+       while (!isspace(*lineptr & 255) && *lineptr)
          lineptr ++;
 
        if (!*lineptr)
@@ -570,12 +570,12 @@ WriteProlog(const char *title,            /* I - Title of job */
 
        for (i = 0; *lineptr && i < 4; i ++)
        {
-         while (isspace(*lineptr))
+         while (isspace(*lineptr & 255))
            lineptr ++;
 
          valptr = lineptr;
 
-         while (!isspace(*lineptr) && *lineptr)
+         while (!isspace(*lineptr & 255) && *lineptr)
            lineptr ++;
 
           if (*lineptr)
@@ -1071,7 +1071,7 @@ write_line(int     row,           /* I - Row number (0 to N) */
        while (col < SizeColumns && line->ch != 0 && attr == line->attr)
        {
           if (Directions[Chars[line->ch] / 256] > 0 &&
-             !ispunct(line->ch) && !isspace(line->ch))
+             !ispunct(line->ch & 255) && !isspace(line->ch & 255))
            break;
 
          col ++;
@@ -1079,7 +1079,7 @@ write_line(int     row,           /* I - Row number (0 to N) */
        }
 
         for (i = 1; start < line; i ++, start ++)
-         if (!isspace(start->ch))
+         if (!isspace(start->ch & 255))
            write_string(col - i, row, 1, start);
       }
     }
@@ -1299,5 +1299,5 @@ write_text(const char *s) /* I - String to write */
 
 
 /*
- * End of "$Id: texttops.c,v 1.34.2.12 2003/01/07 18:27:01 mike Exp $".
+ * End of "$Id: texttops.c,v 1.34.2.13 2004/02/25 20:01:37 mike Exp $".
  */
index 52108113af47808d00de4982e9404da8b10d7228..6d96060159a6f2489e31aec71c73f06384362838 100644 (file)
@@ -150,7 +150,7 @@ static GBool grabArg(ArgDesc *arg, int i, int *argc, char *argv[]) {
 GBool isInt(char *s) {
   if (*s == '-' || *s == '+')
     ++s;
-  while (isdigit(*s))
+  while (isdigit(*s & 255))
     ++s;
   if (*s)
     return gFalse;
@@ -163,13 +163,13 @@ GBool isFP(char *s) {
   if (*s == '-' || *s == '+')
     ++s;
   n = 0;
-  while (isdigit(*s)) {
+  while (isdigit(*s & 255)) {
     ++s;
     ++n;
   }
   if (*s == '.')
     ++s;
-  while (isdigit(*s)) {
+  while (isdigit(*s & 255)) {
     ++s;
     ++n;
   }
@@ -178,11 +178,11 @@ GBool isFP(char *s) {
     if (*s == '-' || *s == '+')
       ++s;
     n = 0;
-    if (!isdigit(*s))
+    if (!isdigit(*s & 255))
       return gFalse;
     do {
       ++s;
-    } while (isdigit(*s));
+    } while (isdigit(*s & 255));
   }
   if (*s)
     return gFalse;
index ca6002e71876141b1b8414c8e7bb73993f5d1e8b..5d3b443473b2b6db42ec3f3a203bc7a655b4cfe9 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: classes.c,v 1.34.2.17 2003/09/15 20:11:07 mike Exp $"
+ * "$Id: classes.c,v 1.34.2.18 2004/02/25 20:01:37 mike Exp $"
  *
  *   Printer class routines for the Common UNIX Printing System (CUPS).
  *
@@ -368,7 +368,7 @@ LoadAllClasses(void)
 
     len = strlen(line);
 
-    while (len > 0 && isspace(line[len - 1]))
+    while (len > 0 && isspace(line[len - 1] & 255))
     {
       len --;
       line[len] = '\0';
@@ -378,14 +378,14 @@ LoadAllClasses(void)
     * Extract the name from the beginning of the line...
     */
 
-    for (value = line; isspace(*value); value ++);
+    for (value = line; isspace(*value & 255); value ++);
 
-    for (nameptr = name; *value != '\0' && !isspace(*value) &&
+    for (nameptr = name; *value != '\0' && !isspace(*value & 255) &&
                             nameptr < (name + sizeof(name) - 1);)
       *nameptr++ = *value++;
     *nameptr = '\0';
 
-    while (isspace(*value))
+    while (isspace(*value & 255))
       value ++;
 
     if (name[0] == '\0')
@@ -494,7 +494,7 @@ LoadAllClasses(void)
       * Set the initial queue state message...
       */
 
-      while (isspace(*value))
+      while (isspace(*value & 255))
         value ++;
 
       strlcpy(p->state_message, value, sizeof(p->state_message));
@@ -516,19 +516,19 @@ LoadAllClasses(void)
       * Set the initial job sheets...
       */
 
-      for (valueptr = value; *valueptr && !isspace(*valueptr); valueptr ++);
+      for (valueptr = value; *valueptr && !isspace(*valueptr & 255); valueptr ++);
 
       if (*valueptr)
         *valueptr++ = '\0';
 
       SetString(&p->job_sheets[0], value);
 
-      while (isspace(*valueptr))
+      while (isspace(*valueptr & 255))
         valueptr ++;
 
       if (*valueptr)
       {
-        for (value = valueptr; *valueptr && !isspace(*valueptr); valueptr ++);
+        for (value = valueptr; *valueptr && !isspace(*valueptr & 255); valueptr ++);
 
        if (*valueptr)
           *valueptr++ = '\0';
@@ -675,5 +675,5 @@ SaveAllClasses(void)
 
 
 /*
- * End of "$Id: classes.c,v 1.34.2.17 2003/09/15 20:11:07 mike Exp $".
+ * End of "$Id: classes.c,v 1.34.2.18 2004/02/25 20:01:37 mike Exp $".
  */
index 9bf53adb2a311323510d718c10a39360da4ab964..f2cfd1e9036b172c86d80399e8a68e056bc84167 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: client.c,v 1.91.2.76 2004/02/25 16:22:01 mike Exp $"
+ * "$Id: client.c,v 1.91.2.77 2004/02/25 20:01:37 mike Exp $"
  *
  *   Client routines for the Common UNIX Printing System (CUPS) scheduler.
  *
@@ -3132,7 +3132,8 @@ pipe_command(client_t *con,               /* I - Client connection */
 
       commptr --;
     }
-    else if (*commptr == '%')
+    else if (*commptr == '%' && isxdigit(commptr[1] & 255) &&
+             isxdigit(commptr[2] & 255))
     {
       if (commptr[1] >= '0' && commptr[1] <= '9')
         *commptr = (commptr[1] - '0') << 4;
@@ -3521,5 +3522,5 @@ CDSAWriteFunc(SSLConnectionRef connection,        /* I  - SSL/TLS connection */
 
 
 /*
- * End of "$Id: client.c,v 1.91.2.76 2004/02/25 16:22:01 mike Exp $".
+ * End of "$Id: client.c,v 1.91.2.77 2004/02/25 20:01:37 mike Exp $".
  */
index c9860bbb0b2ec50a3500803ff5bcae8914b972c9..c1c34ed1ddd6aa87a2d7b81b955c4c4a921b4039 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: conf.c,v 1.77.2.48 2004/02/24 21:36:59 mike Exp $"
+ * "$Id: conf.c,v 1.77.2.49 2004/02/25 20:01:37 mike Exp $"
  *
  *   Configuration routines for the Common UNIX Printing System (CUPS).
  *
@@ -1530,13 +1530,13 @@ read_configuration(cups_file_t *fp)     /* I - File to read from */
 
              if (units && *units)
              {
-               if (tolower(units[0]) == 'g')
+               if (tolower(units[0] & 255) == 'g')
                  n *= 1024 * 1024 * 1024;
-               else if (tolower(units[0]) == 'm')
+               else if (tolower(units[0] & 255) == 'm')
                  n *= 1024 * 1024;
-               else if (tolower(units[0]) == 'k')
+               else if (tolower(units[0] & 255) == 'k')
                  n *= 1024;
-               else if (tolower(units[0]) == 't')
+               else if (tolower(units[0] & 255) == 't')
                  n *= 262144;
              }
 
@@ -1618,7 +1618,7 @@ read_location(cups_file_t *fp,            /* I - Configuration file */
 
     len = strlen(line);
 
-    while (len > 0 && isspace(line[len - 1]))
+    while (len > 0 && isspace(line[len - 1] & 255))
     {
       len --;
       line[len] = '\0';
@@ -1628,14 +1628,14 @@ read_location(cups_file_t *fp,          /* I - Configuration file */
     * Extract the name from the beginning of the line...
     */
 
-    for (value = line; isspace(*value); value ++);
+    for (value = line; isspace(*value & 255); value ++);
 
-    for (nameptr = name; *value != '\0' && !isspace(*value) &&
+    for (nameptr = name; *value != '\0' && !isspace(*value & 255) &&
                              nameptr < (name + sizeof(name) - 1);)
       *nameptr++ = *value++;
     *nameptr = '\0';
 
-    while (isspace(*value))
+    while (isspace(*value & 255))
       value ++;
 
     if (name[0] == '\0')
@@ -1657,7 +1657,7 @@ read_location(cups_file_t *fp,            /* I - Configuration file */
       while (*value)
       {
         for (valptr = value;
-            !isspace(*valptr) && *valptr != '>' && *valptr;
+            !isspace(*valptr & 255) && *valptr != '>' && *valptr;
             valptr ++);
 
        if (*valptr)
@@ -1681,7 +1681,7 @@ read_location(cups_file_t *fp,            /* I - Configuration file */
          LogMessage(L_WARN, "Unknown request type %s on line %d!", value,
                     linenum);
 
-        for (value = valptr; isspace(*value) || *value == '>'; value ++);
+        for (value = valptr; isspace(*value & 255) || *value == '>'; value ++);
       }
 
       if (strcasecmp(name, "<LimitExcept") == 0)
@@ -1744,7 +1744,7 @@ read_location(cups_file_t *fp,            /* I - Configuration file */
 
        value += 4;
 
-       while (isspace(*value))
+       while (isspace(*value & 255))
          value ++;
       }
 
@@ -1786,7 +1786,7 @@ read_location(cups_file_t *fp,            /* I - Configuration file */
        else
          DenyIP(loc, ones, zeros);
       }
-      else if (value[0] == '*' || value[0] == '.' || !isdigit(value[0]))
+      else if (value[0] == '*' || value[0] == '.' || !isdigit(value[0] & 255))
       {
        /*
         * Host or domain name...
@@ -1903,7 +1903,7 @@ read_location(cups_file_t *fp,            /* I - Configuration file */
       */
 
       for (valptr = value;
-          !isspace(*valptr) && *valptr != '>' && *valptr;
+          !isspace(*valptr & 255) && *valptr != '>' && *valptr;
           valptr ++);
 
       if (*valptr)
@@ -1927,14 +1927,14 @@ read_location(cups_file_t *fp,          /* I - Configuration file */
 
       for (value = valptr; *value;)
       {
-        for (valptr = value; !isspace(*valptr) && *valptr; valptr ++);
+        for (valptr = value; !isspace(*valptr & 255) && *valptr; valptr ++);
 
        if (*valptr)
          *valptr++ = '\0';
 
         AddName(loc, value);
 
-        for (value = valptr; isspace(*value); value ++);
+        for (value = valptr; isspace(*value & 255); value ++);
       }
     }
     else if (strcasecmp(name, "Satisfy") == 0)
@@ -2043,7 +2043,7 @@ get_address(const char  *value,           /* I - Value string */
 
   if (portname[0] != '\0')
   {
-    if (isdigit(portname[0]))
+    if (isdigit(portname[0] & 255))
     {
 #ifdef AF_INET6
       if (address->addr.sa_family == AF_INET6)
@@ -2306,5 +2306,5 @@ CDSAGetServerCerts(void)
 
 
 /*
- * End of "$Id: conf.c,v 1.77.2.48 2004/02/24 21:36:59 mike Exp $".
+ * End of "$Id: conf.c,v 1.77.2.49 2004/02/25 20:01:37 mike Exp $".
  */
index 74b1e5af7079c83e87ad96068795129f8340584b..c4eb828205bf78c33adc614452a5d611a583c4ed 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: cups-lpd.c,v 1.24.2.15 2004/02/17 21:32:58 mike Exp $"
+ * "$Id: cups-lpd.c,v 1.24.2.16 2004/02/25 20:01:37 mike Exp $"
  *
  *   Line Printer Daemon interface for the Common UNIX Printing System (CUPS).
  *
@@ -208,9 +208,9 @@ main(int  argc,                     /* I - Number of command-line arguments */
   command = line[0];
   dest    = line + 1;
 
-  for (list = dest + 1; *list && !isspace(*list); list ++);
+  for (list = dest + 1; *list && !isspace(*list & 255); list ++);
 
-  while (isspace(*list))
+  while (isspace(*list & 255))
     *list++ = '\0';
 
  /*
@@ -262,8 +262,8 @@ main(int  argc,                     /* I - Number of command-line arguments */
 
         agent = list;
 
-       for (; *list && !isspace(*list); list ++);
-       while (isspace(*list))
+       for (; *list && !isspace(*list & 255); list ++);
+       while (isspace(*list & 255))
          *list++ = '\0';
 
         syslog(LOG_INFO, "Remove jobs %s on %s by %s", list, dest, agent);
@@ -479,8 +479,8 @@ recv_print_job(const char    *dest, /* I - Destination */
     command = line[0];
     count   = line + 1;
 
-    for (name = count + 1; *name && !isspace(*name); name ++);
-    while (isspace(*name))
+    for (name = count + 1; *name && !isspace(*name & 255); name ++);
+    while (isspace(*name & 255))
       *name++ = '\0';
 
     switch (command)
@@ -836,9 +836,9 @@ remove_jobs(const char *dest,               /* I - Destination */
     * Skip job ID in list...
     */
 
-    while (isdigit(*list))
+    while (isdigit(*list & 255))
       list ++;
-    while (isspace(*list))
+    while (isspace(*list & 255))
       list ++;
 
    /*
@@ -1300,5 +1300,5 @@ smart_gets(char *s,       /* I - Pointer to line buffer */
 
 
 /*
- * End of "$Id: cups-lpd.c,v 1.24.2.15 2004/02/17 21:32:58 mike Exp $".
+ * End of "$Id: cups-lpd.c,v 1.24.2.16 2004/02/25 20:01:37 mike Exp $".
  */
index 9c72a2fceb36775be93f0c3636f605fd6f5f00e2..96b4e94d74c4df2594451c96bc25f56fc7e26247 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: devices.c,v 1.14.2.4 2003/01/07 18:27:19 mike Exp $"
+ * "$Id: devices.c,v 1.14.2.5 2004/02/25 20:01:37 mike Exp $"
  *
  *   Device scanning routines for the Common UNIX Printing System (CUPS).
  *
@@ -23,7 +23,9 @@
  *
  * Contents:
  *
- *   LoadDevices() - Load all available devices.
+ *   LoadDevices()     - Load all available devices.
+ *   compare_devs()    - Compare PPD file make and model names for sorting.
+ *   sigalrm_handler() - Handle alarm signals for backends that get hung
  */
 
 /*
@@ -342,12 +344,12 @@ LoadDevices(const char *d)        /* I - Directory to scan */
 
 
 /*
- * 'compare_devs()' - Compare PPD file make and model names for sorting.
+ * 'compare_devs()' - Compare device names for sorting.
  */
 
 static int                             /* O - Result of comparison */
-compare_devs(const dev_info_t *d0,     /* I - First PPD file */
-             const dev_info_t *d1)     /* I - Second PPD file */
+compare_devs(const dev_info_t *d0,     /* I - First device */
+             const dev_info_t *d1)     /* I - Second device */
 {
   const char   *s,                     /* First name */
                *t;                     /* Second name */
@@ -369,7 +371,7 @@ compare_devs(const dev_info_t *d0,  /* I - First PPD file */
 
   while (*s && *t)
   {
-    if (isdigit(*s) && isdigit(*t))
+    if (isdigit(*s & 255) && isdigit(*t & 255))
     {
      /*
       * Got a number; start by skipping leading 0's...
@@ -384,7 +386,7 @@ compare_devs(const dev_info_t *d0,  /* I - First PPD file */
       * Skip equal digits...
       */
 
-      while (isdigit(*s) && *s == *t)
+      while (isdigit(*s & 255) && *s == *t)
       {
         s ++;
        t ++;
@@ -394,11 +396,11 @@ compare_devs(const dev_info_t *d0,        /* I - First PPD file */
       * Bounce out if *s and *t aren't both digits...
       */
 
-      if (isdigit(*s) && !isdigit(*t))
+      if (isdigit(*s & 255) && !isdigit(*t & 255))
         return (1);
-      else if (!isdigit(*s) && isdigit(*t))
+      else if (!isdigit(*s & 255) && isdigit(*t & 255))
         return (-1);
-      else if (!isdigit(*s) || !isdigit(*t))
+      else if (!isdigit(*s & 255) || !isdigit(*t & 255))
         continue;     
 
       if (*s < *t)
@@ -414,13 +416,13 @@ compare_devs(const dev_info_t *d0,        /* I - First PPD file */
       s ++;
       t ++;
 
-      while (isdigit(*s))
+      while (isdigit(*s & 255))
       {
         digits ++;
        s ++;
       }
 
-      while (isdigit(*t))
+      while (isdigit(*t & 255))
       {
         digits --;
        t ++;
@@ -478,5 +480,5 @@ sigalrm_handler(int sig)    /* I - Signal number */
 
 
 /*
- * End of "$Id: devices.c,v 1.14.2.4 2003/01/07 18:27:19 mike Exp $".
+ * End of "$Id: devices.c,v 1.14.2.5 2004/02/25 20:01:37 mike Exp $".
  */
index ececd13e7bc80927d394090edee1924a9aa9f18d..f805b6192f989db7b0a48c9e18f3767fdd552279 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: dirsvc.c,v 1.73.2.45 2004/02/24 19:04:05 mike Exp $"
+ * "$Id: dirsvc.c,v 1.73.2.46 2004/02/25 20:01:37 mike Exp $"
  *
  *   Directory services routines for the Common UNIX Printing System (CUPS).
  *
@@ -1304,7 +1304,7 @@ UpdateCUPSBrowse(void)
     if (*pptr == '\"')
       pptr ++;
 
-    while (*pptr && isspace(*pptr))
+    while (*pptr && isspace(*pptr & 255))
       pptr ++;
 
     if (*pptr == '\"')
@@ -1320,7 +1320,7 @@ UpdateCUPSBrowse(void)
       if (*pptr == '\"')
        pptr ++;
 
-      while (*pptr && isspace(*pptr))
+      while (*pptr && isspace(*pptr & 255))
        pptr ++;
 
       if (*pptr == '\"')
@@ -1969,5 +1969,5 @@ UpdateSLPBrowse(void)
 
 
 /*
- * End of "$Id: dirsvc.c,v 1.73.2.45 2004/02/24 19:04:05 mike Exp $".
+ * End of "$Id: dirsvc.c,v 1.73.2.46 2004/02/25 20:01:37 mike Exp $".
  */
index 8ffc1371c69c7354be5c132f89fa82959230efb5..1d3b49bf2302df2f2408e2a340e3bdf1a6606f55 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: ipp.c,v 1.127.2.78 2004/02/17 21:32:58 mike Exp $"
+ * "$Id: ipp.c,v 1.127.2.79 2004/02/25 20:01:37 mike Exp $"
  *
  *   IPP routines for the Common UNIX Printing System (CUPS) scheduler.
  *
@@ -2333,7 +2333,7 @@ copy_banner(client_t   *con,      /* I - Client connection */
       */
 
       for (s = attrname; (ch = cupsFileGetChar(in)) != EOF;)
-        if (!isalpha(ch) && ch != '-' && ch != '?')
+        if (!isalpha(ch & 255) && ch != '-' && ch != '?')
           break;
        else if (s < (attrname + sizeof(attrname) - 1))
           *s++ = ch;
@@ -2602,7 +2602,7 @@ copy_model(const char *from,              /* I - Source file */
     */
 
     strlcpy(system_paper, paper_result, sizeof(system_paper));
-    system_paper[0] = toupper(system_paper[0]);
+    system_paper[0] = toupper(system_paper[0] & 255);
 
     num_defaults = ppd_add_default("PageSize", system_paper, 
                                   num_defaults, &defaults);
@@ -4419,7 +4419,7 @@ ppd_parse_line(const char *line,  /* I - Line */
   * Read the option name...
   */
 
-  for (line += 8, olen --; isalnum(*line); line ++)
+  for (line += 8, olen --; isalnum(*line & 255); line ++)
     if (olen > 0)
     {
       *option++ = *line;
@@ -4444,10 +4444,10 @@ ppd_parse_line(const char *line,        /* I - Line */
   * Now grab the option choice, skipping leading whitespace...
   */
 
-  while (isspace(*line))
+  while (isspace(*line & 255))
     line ++;
 
-  for (clen --; isalnum(*line); line ++)
+  for (clen --; isalnum(*line & 255); line ++)
     if (clen > 0)
     {
       *choice++ = *line;
@@ -6914,5 +6914,5 @@ validate_user(client_t   *con,            /* I - Client connection */
 
 
 /*
- * End of "$Id: ipp.c,v 1.127.2.78 2004/02/17 21:32:58 mike Exp $".
+ * End of "$Id: ipp.c,v 1.127.2.79 2004/02/25 20:01:37 mike Exp $".
  */
index 2dc6c987498589f9b10197efde2be70edbbad74f..db6b368e3446d293db346fa90f3e237de9e55beb 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: job.c,v 1.124.2.83 2004/02/03 12:56:07 mike Exp $"
+ * "$Id: job.c,v 1.124.2.84 2004/02/25 20:01:37 mike Exp $"
  *
  *   Job management routines for the Common UNIX Printing System (CUPS).
  *
@@ -1682,8 +1682,8 @@ StartJob(int       id,                    /* I - Job ID */
         snprintf(language, sizeof(language), "LANG=%c%c_%c%c",
                 attr->values[0].string.text[0],
                 attr->values[0].string.text[1],
-                toupper(attr->values[0].string.text[3]),
-                toupper(attr->values[0].string.text[4]));
+                toupper(attr->values[0].string.text[3] & 255),
+                toupper(attr->values[0].string.text[4] & 255));
         break;
   }
 
@@ -2322,7 +2322,7 @@ UpdateJob(job_t *job)             /* I - Job to check */
     * Skip leading whitespace in the message...
     */
 
-    while (isspace(*message))
+    while (isspace(*message & 255))
       message ++;
 
    /*
@@ -2877,5 +2877,5 @@ set_hold_until(job_t *job,                /* I - Job to update */
 
 
 /*
- * End of "$Id: job.c,v 1.124.2.83 2004/02/03 12:56:07 mike Exp $".
+ * End of "$Id: job.c,v 1.124.2.84 2004/02/25 20:01:37 mike Exp $".
  */
index 097d6742bcdec8a822a28eca1b904457c1961816..bb7f757012754181f2a96c33d2b23549a0caf0b6 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: mime.c,v 1.7.2.10 2003/03/28 22:29:49 mike Exp $"
+ * "$Id: mime.c,v 1.7.2.11 2004/02/25 20:01:37 mike Exp $"
  *
  *   MIME database file routines for the Common UNIX Printing System (CUPS).
  *
@@ -348,7 +348,7 @@ load_types(mime_t     *mime,                /* I - MIME database */
 
     while (*lineptr != '/' && *lineptr != '\n' && *lineptr != '\0' &&
            (temp - super + 1) < MIME_MAX_SUPER)
-      *temp++ = tolower(*lineptr++);
+      *temp++ = tolower(*lineptr++ & 255);
 
     *temp = '\0';
 
@@ -360,7 +360,7 @@ load_types(mime_t     *mime,                /* I - MIME database */
 
     while (*lineptr != ' ' && *lineptr != '\t' && *lineptr != '\n' &&
            *lineptr != '\0' && (temp - type + 1) < MIME_MAX_TYPE)
-      *temp++ = tolower(*lineptr++);
+      *temp++ = tolower(*lineptr++ & 255);
 
     *temp = '\0';
 
@@ -424,7 +424,7 @@ load_convs(mime_t     *mime,                /* I - MIME database */
     */
 
     for (lineptr = line + strlen(line) - 1;
-         lineptr >= line && isspace(*lineptr);
+         lineptr >= line && isspace(*lineptr & 255);
         lineptr --)
       *lineptr = '\0';
 
@@ -444,7 +444,7 @@ load_convs(mime_t     *mime,                /* I - MIME database */
 
     while (*lineptr != '/' && *lineptr != '\n' && *lineptr != '\0' &&
            (temp - super + 1) < MIME_MAX_SUPER)
-      *temp++ = tolower(*lineptr++);
+      *temp++ = tolower(*lineptr++ & 255);
 
     *temp = '\0';
 
@@ -456,7 +456,7 @@ load_convs(mime_t     *mime,                /* I - MIME database */
 
     while (*lineptr != ' ' && *lineptr != '\t' && *lineptr != '\n' &&
            *lineptr != '\0' && (temp - type + 1) < MIME_MAX_TYPE)
-      *temp++ = tolower(*lineptr++);
+      *temp++ = tolower(*lineptr++ & 255);
 
     *temp = '\0';
 
@@ -515,7 +515,7 @@ load_convs(mime_t     *mime,                /* I - MIME database */
 
     while (*lineptr != '/' && *lineptr != '\n' && *lineptr != '\0' &&
            (temp - super + 1) < MIME_MAX_SUPER)
-      *temp++ = tolower(*lineptr++);
+      *temp++ = tolower(*lineptr++ & 255);
 
     *temp = '\0';
 
@@ -527,7 +527,7 @@ load_convs(mime_t     *mime,                /* I - MIME database */
 
     while (*lineptr != ' ' && *lineptr != '\t' && *lineptr != '\n' &&
            *lineptr != '\0' && (temp - type + 1) < MIME_MAX_TYPE)
-      *temp++ = tolower(*lineptr++);
+      *temp++ = tolower(*lineptr++ & 255);
 
     *temp = '\0';
 
@@ -583,5 +583,5 @@ delete_rules(mime_magic_t *rules)   /* I - Rules to free */
 
 
 /*
- * End of "$Id: mime.c,v 1.7.2.10 2003/03/28 22:29:49 mike Exp $".
+ * End of "$Id: mime.c,v 1.7.2.11 2004/02/25 20:01:37 mike Exp $".
  */
index aedf95c958fc1c232126d03db0e34815e0bf85d4..2ed24a2ef10b2b3c2142042dfd8ffbd385bda0f9 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: ppds.c,v 1.14.2.12 2003/09/04 14:48:14 mike Exp $"
+ * "$Id: ppds.c,v 1.14.2.13 2004/02/25 20:01:37 mike Exp $"
  *
  *   PPD scanning routines for the Common UNIX Printing System (CUPS).
  *
@@ -300,7 +300,7 @@ compare_ppds(const ppd_info_t *p0,  /* I - First PPD file */
 
   while (*s && *t)
   {
-    if (isdigit(*s) && isdigit(*t))
+    if (isdigit(*s & 255) && isdigit(*t & 255))
     {
      /*
       * Got a number; start by skipping leading 0's...
@@ -315,7 +315,7 @@ compare_ppds(const ppd_info_t *p0,  /* I - First PPD file */
       * Skip equal digits...
       */
 
-      while (isdigit(*s) && *s == *t)
+      while (isdigit(*s & 255) && *s == *t)
       {
         s ++;
        t ++;
@@ -325,11 +325,11 @@ compare_ppds(const ppd_info_t *p0,        /* I - First PPD file */
       * Bounce out if *s and *t aren't both digits...
       */
 
-      if (isdigit(*s) && !isdigit(*t))
+      if (isdigit(*s & 255) && !isdigit(*t & 255))
         return (1);
-      else if (!isdigit(*s) && isdigit(*t))
+      else if (!isdigit(*s & 255) && isdigit(*t & 255))
         return (-1);
-      else if (!isdigit(*s) || !isdigit(*t))
+      else if (!isdigit(*s & 255) || !isdigit(*t & 255))
         continue;     
 
       if (*s < *t)
@@ -345,13 +345,13 @@ compare_ppds(const ppd_info_t *p0,        /* I - First PPD file */
       s ++;
       t ++;
 
-      while (isdigit(*s))
+      while (isdigit(*s & 255))
       {
         digits ++;
        s ++;
       }
 
-      while (isdigit(*t))
+      while (isdigit(*t & 255))
       {
         digits --;
        t ++;
@@ -368,9 +368,9 @@ compare_ppds(const ppd_info_t *p0,  /* I - First PPD file */
       else if (diff)
         return (diff);
     }
-    else if (tolower(*s) < tolower(*t))
+    else if (tolower(*s & 255) < tolower(*t & 255))
       return (-1);
-    else if (tolower(*s) > tolower(*t))
+    else if (tolower(*s & 255) > tolower(*t & 255))
       return (1);
     else
     {
@@ -587,7 +587,7 @@ load_ppds(const char *d,            /* I - Actual directory */
     else
       strcpy(make_model, model_name);
 
-    while (isspace(make_model[0]))
+    while (isspace(make_model[0] & 255))
       cups_strcpy(make_model, make_model + 1);
 
     if (!make_model[0])
@@ -597,7 +597,7 @@ load_ppds(const char *d,            /* I - Actual directory */
     * See if we got a manufacturer...
     */
 
-    while (isspace(manufacturer[0]))
+    while (isspace(manufacturer[0] & 255))
       cups_strcpy(manufacturer, manufacturer + 1);
 
     if (!manufacturer[0] || strcmp(manufacturer, "ESP") == 0)
@@ -780,5 +780,5 @@ load_ppds(const char *d,            /* I - Actual directory */
 
 
 /*
- * End of "$Id: ppds.c,v 1.14.2.12 2003/09/04 14:48:14 mike Exp $".
+ * End of "$Id: ppds.c,v 1.14.2.13 2004/02/25 20:01:37 mike Exp $".
  */
index 034880c3ea3d2d3990f46800b8b416d896c67bc2..e2fb9d127a26e30fbc6301bf0fd48d2992769f93 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: printers.c,v 1.93.2.55 2004/02/24 21:36:59 mike Exp $"
+ * "$Id: printers.c,v 1.93.2.56 2004/02/25 20:01:37 mike Exp $"
  *
  *   Printer routines for the Common UNIX Printing System (CUPS).
  *
@@ -823,7 +823,7 @@ LoadAllPrinters(void)
 
     len = strlen(line);
 
-    while (len > 0 && isspace(line[len - 1]))
+    while (len > 0 && isspace(line[len - 1] & 255))
     {
       len --;
       line[len] = '\0';
@@ -833,14 +833,14 @@ LoadAllPrinters(void)
     * Extract the name from the beginning of the line...
     */
 
-    for (value = line; isspace(*value); value ++);
+    for (value = line; isspace(*value & 255); value ++);
 
-    for (nameptr = name; *value != '\0' && !isspace(*value) &&
+    for (nameptr = name; *value != '\0' && !isspace(*value & 255) &&
                              nameptr < (name + sizeof(name) - 1);)
       *nameptr++ = *value++;
     *nameptr = '\0';
 
-    while (isspace(*value))
+    while (isspace(*value & 255))
       value ++;
 
     if (name[0] == '\0')
@@ -929,7 +929,7 @@ LoadAllPrinters(void)
       * Set the initial queue state message...
       */
 
-      while (isspace(*value))
+      while (isspace(*value & 255))
         value ++;
 
       strlcpy(p->state_message, value, sizeof(p->state_message));
@@ -951,19 +951,19 @@ LoadAllPrinters(void)
       * Set the initial job sheets...
       */
 
-      for (valueptr = value; *valueptr && !isspace(*valueptr); valueptr ++);
+      for (valueptr = value; *valueptr && !isspace(*valueptr & 255); valueptr ++);
 
       if (*valueptr)
         *valueptr++ = '\0';
 
       SetString(&p->job_sheets[0], value);
 
-      while (isspace(*valueptr))
+      while (isspace(*valueptr & 255))
         valueptr ++;
 
       if (*valueptr)
       {
-        for (value = valueptr; *valueptr && !isspace(*valueptr); valueptr ++);
+        for (value = valueptr; *valueptr && !isspace(*valueptr & 255); valueptr ++);
 
        if (*valueptr)
           *valueptr++ = '\0';
@@ -1714,10 +1714,10 @@ SetPrinterReasons(printer_t  *p,        /* I - Printer */
     * Skip leading whitespace and commas...
     */
 
-    while (isspace(*sptr) || *sptr == ',')
+    while (isspace(*sptr & 255) || *sptr == ',')
       sptr ++;
 
-    for (rptr = reason; *sptr && !isspace(*sptr) && *sptr != ','; sptr ++)
+    for (rptr = reason; *sptr && !isspace(*sptr & 255) && *sptr != ','; sptr ++)
       if (rptr < (reason + sizeof(reason) - 1))
         *rptr++ = *sptr;
 
@@ -2415,5 +2415,5 @@ write_irix_state(printer_t *p)            /* I - Printer to update */
 
 
 /*
- * End of "$Id: printers.c,v 1.93.2.55 2004/02/24 21:36:59 mike Exp $".
+ * End of "$Id: printers.c,v 1.93.2.56 2004/02/25 20:01:37 mike Exp $".
  */
index 9075c9e0c2a19fc17dd64b17f26f7cb10e184d94..9596aeba48b55af12257528e37f6fbd445ab7224 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: type.c,v 1.11.2.11 2003/04/07 18:03:48 mike Exp $"
+ * "$Id: type.c,v 1.11.2.12 2004/02/25 20:01:37 mike Exp $"
  *
  *   MIME typing routines for the Common UNIX Printing System (CUPS).
  *
@@ -175,7 +175,7 @@ mimeAddTypeRule(mime_type_t *mt,    /* I - Type to add to */
 
   while (*rule != '\0')
   {
-    while (isspace(*rule))
+    while (isspace(*rule & 255))
       rule ++;
 
     if (*rule == '(')
@@ -285,13 +285,13 @@ mimeAddTypeRule(mime_type_t *mt,  /* I - Type to add to */
       invert = 1;
       rule ++;
     }
-    else if (isalnum(*rule))
+    else if (isalnum(*rule & 255))
     {
      /*
       * Read an extension name or a function...
       */
 
-      for (ptr = name; isalnum(*rule) && (ptr - name) < (sizeof(name) - 1);)
+      for (ptr = name; isalnum(*rule & 255) && (ptr - name) < (sizeof(name) - 1);)
         *ptr++ = *rule++;
 
       *ptr       = '\0';
@@ -313,7 +313,7 @@ mimeAddTypeRule(mime_type_t *mt,    /* I - Type to add to */
          while ((ptr - value[num_values]) < (sizeof(value[0]) - 1) &&
                 *rule != '\0' && *rule != ',' && *rule != ')')
          {
-           if (isspace(*rule))
+           if (isspace(*rule & 255))
            {
             /*
              * Ignore whitespace...
@@ -346,7 +346,7 @@ mimeAddTypeRule(mime_type_t *mt,    /* I - Type to add to */
              while (*rule != '>' && *rule != '\0' &&
                     (ptr - value[num_values]) < (sizeof(value[0]) - 1))
              {
-               if (isxdigit(rule[0]) && isxdigit(rule[1]))
+               if (isxdigit(rule[0] & 255) && isxdigit(rule[1] & 255))
                {
                  if (isdigit(*rule))
                    *ptr = (*rule++ - '0') << 4;
@@ -1128,5 +1128,5 @@ patmatch(const char *s,           /* I - String to match against */
 
 
 /*
- * End of "$Id: type.c,v 1.11.2.11 2003/04/07 18:03:48 mike Exp $".
+ * End of "$Id: type.c,v 1.11.2.12 2004/02/25 20:01:37 mike Exp $".
  */
index c95a1b1dbe366819e029978822d8d6200de20d7b..3037c94578d99336b629d8f09e828ae358e69def 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * "$Id: cupstestppd.c,v 1.1.2.27 2004/02/17 21:32:58 mike Exp $"
+ * "$Id: cupstestppd.c,v 1.1.2.28 2004/02/25 20:01:37 mike Exp $"
  *
  *   PPD test program for the Common UNIX Printing System (CUPS).
  *
@@ -487,7 +487,7 @@ main(int  argc,                     /* I - Number of command-line arguments */
       if (ppd->modelname != NULL)
       {
         for (ptr = ppd->modelname; *ptr; ptr ++)
-         if (!isalnum(*ptr) && !strchr(" ./-+", *ptr))
+         if (!isalnum(*ptr & 255) && !strchr(" ./-+", *ptr))
            break;
 
        if (*ptr)
@@ -1121,5 +1121,5 @@ usage(void)
 
 
 /*
- * End of "$Id: cupstestppd.c,v 1.1.2.27 2004/02/17 21:32:58 mike Exp $".
+ * End of "$Id: cupstestppd.c,v 1.1.2.28 2004/02/25 20:01:37 mike Exp $".
  */