]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Merge changes from CUPS 1.5rc1-r9815.
authormsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Sun, 5 Jun 2011 17:00:32 +0000 (17:00 +0000)
committermsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Sun, 5 Jun 2011 17:00:32 +0000 (17:00 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/easysw/current@3299 a1ca3aef-8c08-0410-bb20-df032aa958be

CHANGES.txt
INSTALL.txt
README.txt
backend/dnssd.c
config-scripts/cups-common.m4
cups/file.c
doc/help/spec-ppd.html
filter/spec-ppd.shtml

index 53a354bce561376b20e147fc598a5c25dad34216..e79e4884bcb56ee1df96983324b2271bbde761ca 100644 (file)
@@ -1,6 +1,13 @@
-CHANGES.txt - 2011-05-26
+CHANGES.txt - 2011-06-05
 ------------------------
 
+CHANGES IN CUPS V1.5rc1
+
+       - The dnssd backend took too long to discover printers on large or busy
+         networks with the new default timeout used by lpinfo and the web
+         interface. This resulted in "lost" printers.
+
+
 CHANGES IN CUPS V1.5b2
 
        - Documentation updates.
index 8d13a9e38a078ae4db878620f71542c0fd0c3584..cc97983432ad3d8dd62f439588c4b78a23d874f8 100644 (file)
@@ -1,5 +1,5 @@
-INSTALL - CUPS v1.5b2 - 2011-05-26
-----------------------------------
+INSTALL - CUPS v1.5rc1 - 2011-06-05
+-----------------------------------
 
 This file describes how to compile and install CUPS from source code. For more
 information on CUPS see the file called "README.txt".  A complete change log can
index e4761847531ced4c784a21a6af019ddbedc20e59..bb9497e82cc858fa5bb1e631a9b14c90bc69c24e 100644 (file)
@@ -1,5 +1,5 @@
-README - CUPS v1.5b2 - 2011-05-26
----------------------------------
+README - CUPS v1.5rc1 - 2011-06-05
+----------------------------------
 
 Looking for compile instructions?  Read the file "INSTALL.txt"
 instead...
index ac547ab54135e27e9e498ee87655c2ba407f65af..d1392ed2a73db86396893ed90e075dbdfe859d24 100644 (file)
@@ -44,6 +44,7 @@ typedef enum
 {
   CUPS_DEVICE_PRINTER = 0,             /* lpd://... */
   CUPS_DEVICE_IPP,                     /* ipp://... */
+  CUPS_DEVICE_IPPS,                    /* ipps://... */
   CUPS_DEVICE_FAX_IPP,                 /* ipp://... */
   CUPS_DEVICE_PDL_DATASTREAM,          /* socket://... */
   CUPS_DEVICE_RIOUSBPRINT              /* riousbprint://... */
@@ -123,9 +124,11 @@ main(int  argc,                            /* I - Number of command-line args */
                fax_ipp_ref,            /* IPP fax service reference */
                ipp_ref,                /* IPP service reference */
                ipp_tls_ref,            /* IPP w/TLS service reference */
+               ipps_ref,               /* IPP service reference */
                local_fax_ipp_ref,      /* Local IPP fax service reference */
                local_ipp_ref,          /* Local IPP service reference */
                local_ipp_tls_ref,      /* Local IPP w/TLS service reference */
+               local_ipps_ref,         /* Local IPP service reference */
                local_printer_ref,      /* Local LPD service reference */
                pdl_datastream_ref,     /* AppSocket service reference */
                printer_ref,            /* LPD service reference */
@@ -215,6 +218,10 @@ main(int  argc,                            /* I - Number of command-line args */
   DNSServiceBrowse(&ipp_tls_ref, kDNSServiceFlagsShareConnection, 0,
                    "_ipp-tls._tcp", NULL, browse_callback, devices);
 
+  ipps_ref = main_ref;
+  DNSServiceBrowse(&ipp_ref, kDNSServiceFlagsShareConnection, 0,
+                   "_ipps._tcp", NULL, browse_callback, devices);
+
   local_fax_ipp_ref = main_ref;
   DNSServiceBrowse(&local_fax_ipp_ref, kDNSServiceFlagsShareConnection,
                    kDNSServiceInterfaceIndexLocalOnly,
@@ -230,6 +237,11 @@ main(int  argc,                            /* I - Number of command-line args */
                    kDNSServiceInterfaceIndexLocalOnly,
                    "_ipp-tls._tcp", NULL, browse_local_callback, devices);
 
+  local_ipps_ref = main_ref;
+  DNSServiceBrowse(&local_ipp_ref, kDNSServiceFlagsShareConnection,
+                   kDNSServiceInterfaceIndexLocalOnly,
+                  "_ipps._tcp", NULL, browse_local_callback, devices);
+
   local_printer_ref = main_ref;
   DNSServiceBrowse(&local_printer_ref, kDNSServiceFlagsShareConnection,
                    kDNSServiceInterfaceIndexLocalOnly,
@@ -256,8 +268,8 @@ main(int  argc,                             /* I - Number of command-line args */
     FD_ZERO(&input);
     FD_SET(fd, &input);
 
-    timeout.tv_sec  = 1;
-    timeout.tv_usec = 0;
+    timeout.tv_sec  = 0;
+    timeout.tv_usec = 250000;
 
     if (select(fd + 1, &input, NULL, NULL, &timeout) < 0)
       continue;
@@ -280,19 +292,26 @@ main(int  argc,                           /* I - Number of command-line args */
       cups_device_t *best;             /* Best matching device */
       char     device_uri[1024];       /* Device URI */
       int      count;                  /* Number of queries */
-
+      int      sent;                   /* Number of sent */
 
       for (device = (cups_device_t *)cupsArrayFirst(devices),
-               best = NULL, count = 0;
+               best = NULL, count = 0, sent = 0;
            device;
           device = (cups_device_t *)cupsArrayNext(devices))
+      {
+        if (device->sent)
+         sent ++;
+
+        if (device->ref)
+         count ++;
+
         if (!device->ref && !device->sent)
        {
         /*
          * Found the device, now get the TXT record(s) for it...
          */
 
-          if (count < 10)
+          if (count < 20)
          {
            device->ref = main_ref;
 
@@ -338,6 +357,8 @@ main(int  argc,                             /* I - Number of command-line args */
                              best->name, best->device_id, NULL);
            best->sent = 1;
            best       = device;
+
+           sent ++;
          }
          else if (best->priority > device->priority ||
                   (best->priority == device->priority &&
@@ -345,10 +366,17 @@ main(int  argc,                           /* I - Number of command-line args */
           {
            best->sent = 1;
            best       = device;
+
+           sent ++;
          }
          else
+         {
            device->sent = 1;
+
+           sent ++;
+         }
         }
+      }
 
       if (best)
       {
@@ -361,7 +389,11 @@ main(int  argc,                            /* I - Number of command-line args */
        cupsBackendReport("network", device_uri, best->make_and_model,
                          best->name, best->device_id, NULL);
        best->sent = 1;
+       sent ++;
       }
+
+      if (sent == cupsArrayCount(devices))
+       break;
     }
   }
 
@@ -558,9 +590,11 @@ get_device(cups_array_t *devices,  /* I - Device array */
 
   key.name = (char *)serviceName;
 
-  if (!strcmp(regtype, "_ipp._tcp.") ||
-      !strcmp(regtype, "_ipp-tls._tcp."))
+  if (!strcmp(regtype, "_ipp._tcp."))
     key.type = CUPS_DEVICE_IPP;
+  else if (!strcmp(regtype, "_ipps._tcp.") ||
+          !strcmp(regtype, "_ipp-tls._tcp."))
+    key.type = CUPS_DEVICE_IPPS;
   else if (!strcmp(regtype, "_fax-ipp._tcp."))
     key.type = CUPS_DEVICE_FAX_IPP;
   else if (!strcmp(regtype, "_printer._tcp."))
@@ -680,9 +714,11 @@ query_callback(
   if ((ptr = strstr(name, "._")) != NULL)
     *ptr = '\0';
 
-  if (strstr(fullName, "_ipp._tcp.") ||
-      strstr(fullName, "_ipp-tls._tcp."))
+  if (strstr(fullName, "_ipp._tcp."))
     dkey.type = CUPS_DEVICE_IPP;
+  else if (strstr(fullName, "_ipps._tcp.") ||
+           strstr(fullName, "_ipp-tls._tcp."))
+    dkey.type = CUPS_DEVICE_IPPS;
   else if (strstr(fullName, "_fax-ipp._tcp."))
     dkey.type = CUPS_DEVICE_FAX_IPP;
   else if (strstr(fullName, "_printer._tcp."))
@@ -754,9 +790,16 @@ query_callback(
          if (data < datanext)
            memcpy(value, data, datanext - data);
          value[datanext - data] = '\0';
+
+         fprintf(stderr, "DEBUG2: query_callback: \"%s=%s\".\n",
+                 key, value);
        }
        else
+       {
+         fprintf(stderr, "DEBUG2: query_callback: \"%s\" with no value.\n",
+                 key);
          continue;
+       }
 
         if (!_cups_strncasecmp(key, "usb_", 4))
        {
@@ -800,6 +843,7 @@ query_callback(
        else if (!_cups_strcasecmp(key, "priority"))
          device->priority = atoi(value);
        else if ((device->type == CUPS_DEVICE_IPP ||
+                 device->type == CUPS_DEVICE_IPPS ||
                  device->type == CUPS_DEVICE_PRINTER) &&
                 !_cups_strcasecmp(key, "printer-type"))
        {
index a4635c93c371bd8cf3036a7097a0541466ab2237..06dce8181a670f66c5193afcc082d0d94e20438f 100644 (file)
@@ -20,7 +20,7 @@ dnl Set the name of the config header file...
 AC_CONFIG_HEADER(config.h)
 
 dnl Version number information...
-CUPS_VERSION="1.5b2"
+CUPS_VERSION="1.5rc1"
 CUPS_REVISION=""
 #if test -z "$CUPS_REVISION" -a -d .svn; then
 #      CUPS_REVISION="-r`svnversion . | awk -F: '{print $NF}' | sed -e '1,$s/[[a-zA-Z]]*//g'`"
index cd76dde14d8dbc00601491f69a9ca8e61e9c3101..daa09da853d30d9084c0679b63c6de5e0adacec2 100644 (file)
@@ -39,6 +39,7 @@
  *   cupsFilePeekChar()     - Peek at the next character from a file.
  *   cupsFilePrintf()       - Write a formatted string.
  *   cupsFilePutChar()      - Write a character.
+ *   cupsFilePutConf()      - Write a configuration line.
  *   cupsFilePuts()         - Write a string.
  *   cupsFileRead()         - Read from a file.
  *   cupsFileRewind()       - Set the current file position to the beginning of
@@ -52,6 +53,7 @@
  *   cupsFileWrite()        - Write to a file.
  *   cups_compress()        - Compress a buffer of data.
  *   cups_fill()            - Fill the input buffer.
+ *   cups_open()            - Safely open a file for writing.
  *   cups_read()            - Read from a file descriptor.
  *   cups_write()           - Write to a file descriptor.
  */
index 1b24af8d621df836a9137ab3d6e400fecee2dc5c..21a9801184444eb5f31f52602dc42cf6b8238ace 100644 (file)
@@ -604,9 +604,10 @@ f(x) = density * x <sup style='font-size: 100%'>gamma</sup>
 
 <h4>Customizing the Profile Selection Keywords</h4>
 
-<p>The <tt>MediaType</tt> and <tt>Resolution</tt> main keywords can be reassigned to different main keywords, allowing drivers to do color profile selection based on different parameters. The <tt>cupsICCQualifier2</tt> and <tt>cupsICCQualifier3</tt> keywords define the mapping from selector to main keyword:</p>
+<p>The <tt>ColorModel</tt>, <tt>MediaType</tt>, and <tt>Resolution</tt> main keywords can be reassigned to different main keywords, allowing drivers to do color profile selection based on different parameters. The <tt>cupsICCQualifier1</tt>, <tt>cupsICCQualifier2</tt>, and <tt>cupsICCQualifier3</tt> keywords define the mapping from selector to main keyword:</p>
 
 <pre class='command'>
+*cupsICCQualifier1: MainKeyword1
 *cupsICCQualifier2: MainKeyword2
 *cupsICCQualifier3: MainKeyword3
 </pre>
@@ -614,6 +615,7 @@ f(x) = density * x <sup style='font-size: 100%'>gamma</sup>
 <p>The default mapping is as follows:</p>
 
 <pre class='command'>
+*cupsICCQualifier1: ColorModel
 *cupsICCQualifier2: MediaType
 *cupsICCQualifier3: Resolution
 </pre>
index d03f9df5edd04dea28150c79386eb010cd3ccbbb..670e89913c1d0f9c8247615961bddfe11f6f6f24 100644 (file)
@@ -165,9 +165,10 @@ f(x) = density * x <sup style='font-size: 100%'>gamma</sup>
 
 <h4>Customizing the Profile Selection Keywords</h4>
 
-<p>The <tt>MediaType</tt> and <tt>Resolution</tt> main keywords can be reassigned to different main keywords, allowing drivers to do color profile selection based on different parameters. The <tt>cupsICCQualifier2</tt> and <tt>cupsICCQualifier3</tt> keywords define the mapping from selector to main keyword:</p>
+<p>The <tt>ColorModel</tt>, <tt>MediaType</tt>, and <tt>Resolution</tt> main keywords can be reassigned to different main keywords, allowing drivers to do color profile selection based on different parameters. The <tt>cupsICCQualifier1</tt>, <tt>cupsICCQualifier2</tt>, and <tt>cupsICCQualifier3</tt> keywords define the mapping from selector to main keyword:</p>
 
 <pre class='command'>
+*cupsICCQualifier1: MainKeyword1
 *cupsICCQualifier2: MainKeyword2
 *cupsICCQualifier3: MainKeyword3
 </pre>
@@ -175,6 +176,7 @@ f(x) = density * x <sup style='font-size: 100%'>gamma</sup>
 <p>The default mapping is as follows:</p>
 
 <pre class='command'>
+*cupsICCQualifier1: ColorModel
 *cupsICCQualifier2: MediaType
 *cupsICCQualifier3: Resolution
 </pre>