]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
The ippfind and ipptool programs now correctly match hostnames with trailing
authormsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Sun, 1 Feb 2015 02:46:20 +0000 (02:46 +0000)
committermsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Sun, 1 Feb 2015 02:46:20 +0000 (02:46 +0000)
dots (STR #4563)

git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@12464 a1ca3aef-8c08-0410-bb20-df032aa958be

CHANGES-2.0.txt
doc/help/man-cups-files.conf.html
test/ippfind.c
test/ipptool.c

index 0a58c8a56030ce1812244a83dc2a3fa61f78655c..2202d7545113f7d510893627404d69f079a044f4 100644 (file)
@@ -11,8 +11,8 @@ CHANGES IN CUPS V2.0.2
          printers.conf file after a restart (<rdar://problem/16827518>)
        - CUPS did not compile with older versions of GNU TLS (STR #4527)
        - CUPS did not compile without Avahi or mDNSResponder (STR #4523)
-       - ippLength() did not return the correct length for IPP_TAG_CONST string
-         values.
+       - ippLength() did not return the correct length for IPP_TAG_CONST
+         string values.
        - The scheduler incorrectly aborted jobs after a job was restarted
          (<rdar://problem/19129387>)
        - The cups-files.conf file contained the old ServerCertificate/Key
@@ -34,6 +34,8 @@ CHANGES IN CUPS V2.0.2
        - Added a USB quirk rule for Intermec printers (STR #4553)
        - The scheduler did not always log which configuration file had the
          error (STR #4559)
+       - The ippfind and ipptool programs now correctly match hostnames with
+         trailing dots (STR #4563)
 
 
 CHANGES IN CUPS V2.0.1
index 03a8c0d6196e6c5e221309c2b3629f5c9d7dc810..2aa201506f1868df19e82e953dda3ef963a5389e 100644 (file)
@@ -112,8 +112,7 @@ The default is "remroot".
 <dt><a name="RequestRoot"></a><b>RequestRoot </b><i>directory</i>
 <dd style="margin-left: 5.0em">Specifies the directory that contains print jobs and other HTTP request data.
 The default is "/var/spool/cups".
-<dt><a name="Sandboxing"></a><b>Sandboxing off</b>
-<dd style="margin-left: 5.0em"><dt><b>Sandboxing relaxed</b>
+<dt><a name="Sandboxing"></a><b>Sandboxing relaxed</b>
 <dd style="margin-left: 5.0em"><dt><b>Sandboxing strict</b>
 <dd style="margin-left: 5.0em">Specifies the level of security sandboxing that is applied to print filters, backends, and other child processes of the scheduler.
 The default is "strict".
@@ -154,7 +153,7 @@ The default is "lp".
 <a href="man-subscriptions.conf.html?TOPIC=Man+Pages"><b>subscriptions.conf</b>(5),</a>
 CUPS Online Help (<a href="http://localhost:631/help">http://localhost:631/help</a>)
 <h2 class="title"><a name="COPYRIGHT">Copyright</a></h2>
-Copyright &copy; 2007-2014 by Apple Inc.
+Copyright &copy; 2007-2015 by Apple Inc.
 
 </body>
 </html>
index 4ee52c345c7af40100b0290b7990f19e5aad0eaf..bf379f18580aff1e0455d7cf8d027ea3263a8858 100644 (file)
@@ -5,7 +5,7 @@
  * commands such as IPP and Bonjour conformance tests.  This tool is
  * inspired by the UNIX "find" command, thus its name.
  *
- * Copyright 2008-2014 by Apple Inc.
+ * Copyright 2008-2015 by Apple Inc.
  *
  * These coded instructions, statements, and computer programs are the
  * property of Apple Inc. and are protected by Federal copyright
@@ -2564,6 +2564,10 @@ resolve_callback(
   service->host        = strdup(hostTarget);
   service->port        = ntohs(port);
 
+  value = service->host + strlen(service->host) - 1;
+  if (value >= service->host && *value == '.')
+    *value = '\0';
+
  /*
   * Loop through the TXT key/value pairs and add them to an array...
   */
@@ -2635,6 +2639,10 @@ resolve_callback(
   service->host        = strdup(hostTarget);
   service->port        = port;
 
+  value = service->host + strlen(service->host) - 1;
+  if (value >= service->host && *value == '.')
+    *value = '\0';
+
  /*
   * Loop through the TXT key/value pairs and add them to an array...
   */
index ca9f1a7205577f26418a3f97bd36570c2c714415..b151b8930704e65abdc6cd56dc3c3148de3b1b57 100644 (file)
@@ -3,7 +3,7 @@
  *
  * ipptool command for CUPS.
  *
- * Copyright 2007-2014 by Apple Inc.
+ * Copyright 2007-2015 by Apple Inc.
  * Copyright 1997-2007 by Easy Software Products.
  *
  * These coded instructions, statements, and computer programs are the
@@ -3883,6 +3883,10 @@ get_string(ipp_attribute_t *attr,        /* I - IPP attribute */
     if (httpSeparateURI(HTTP_URI_CODING_ALL, ptr, scheme, sizeof(scheme), userpass, sizeof(userpass), buffer, (int)bufsize, &port, resource, sizeof(resource)) < HTTP_URI_STATUS_OK)
       buffer[0] = '\0';
 
+    ptr = buffer + strlen(buffer) - 1;
+    if (ptr >= buffer && *ptr == '.')
+      *ptr = '\0';                     /* Drop trailing "." */
+
     return (buffer);
   }
   else if (flags & _CUPS_WITH_RESOURCE)