[Pkg-cups-devel] r209 - in cupsys/branches/cups-1.2-ubuntu/debian: . patches

Martin Pitt mpitt at costa.debian.org
Tue Apr 25 17:49:14 UTC 2006


Author: mpitt
Date: Tue Apr 25 17:49:13 2006
New Revision: 209

Added:
   cupsys/branches/cups-1.2-ubuntu/debian/patches/56_revert_svn_5438.dpatch   (contents, props changed)
Modified:
   cupsys/branches/cups-1.2-ubuntu/debian/changelog
   cupsys/branches/cups-1.2-ubuntu/debian/patches/00list
Log:
* Add debian/patches/56_revert_svn_5438.dpatch: Revert upstream svn commit
  5438 (fixed handling of products/manufacturers with spaces in the name)
  for now since it causes regressions in gnome-cups-add. Will be reactivated
  later when the issue is sorted out with upstream.



Modified: cupsys/branches/cups-1.2-ubuntu/debian/changelog
==============================================================================
--- cupsys/branches/cups-1.2-ubuntu/debian/changelog	(original)
+++ cupsys/branches/cups-1.2-ubuntu/debian/changelog	Tue Apr 25 17:49:13 2006
@@ -1,8 +1,11 @@
 cupsys (1.1.99.rc3-0ubuntu1) dapper; urgency=low
 
-  * New upstream bug fix release 1.2RC3:
-    - Fixes handling of products/manufacturers with spaces in the name.
-      Closes: LP#33545
+  * New upstream bug fix release 1.2RC3, UVF exception approved by Matt
+    Zimmerman.
+  * Add debian/patches/56_revert_svn_5438.dpatch: Revert upstream svn commit
+    5438 (fixed handling of products/manufacturers with spaces in the name)
+    for now since it causes regressions in gnome-cups-add. Will be reactivated
+    later when the issue is sorted out with upstream.
   * Update patches for new upstream release.
   * Remove debian/patches/20_httpGetHostname_crash.dpatch, fixed upstream.
   * debian/patches/08_cupsd.conf.conf.d.dpatch:
@@ -17,14 +20,14 @@
   * debian/cupsys.postinst: If upgrading from Breezy, adapt the inclusion of
     external browsing configuration in cupsd.conf to retain the correct
     setting for modified cupsd.conf files.
-  * debian/cupsys.config: 
+  * debian/cupsys.config:
     - Fix handling of cupsd-browsing.conf -> cups.d/browse.conf transition for
-      breezy->dapper upgrades. 
+      breezy->dapper upgrades.
     - Fix browse.conf parsing to set the correct debconf default value, so
-      that the browse setting is not reset to 'off' on upgrades. 
+      that the browse setting is not reset to 'off' on upgrades.
       Closes: LP#38704
 
- -- Martin Pitt <martin.pitt at ubuntu.com>  Tue, 25 Apr 2006 15:58:01 +0200
+ -- Martin Pitt <martin.pitt at ubuntu.com>  Tue, 25 Apr 2006 19:43:33 +0200
 
 cupsys (1.1.99.rc2-0ubuntu2) dapper; urgency=low
 

Modified: cupsys/branches/cups-1.2-ubuntu/debian/patches/00list
==============================================================================
--- cupsys/branches/cups-1.2-ubuntu/debian/patches/00list	(original)
+++ cupsys/branches/cups-1.2-ubuntu/debian/patches/00list	Tue Apr 25 17:49:13 2006
@@ -18,4 +18,5 @@
 47_pid.dpatch
 #48_stdlib.dpatch
 55_ppd_okidata_name.dpatch
+56_revert_svn_5438.dpatch
 ubuntu-nowebadmin.dpatch

Added: cupsys/branches/cups-1.2-ubuntu/debian/patches/56_revert_svn_5438.dpatch
==============================================================================
--- (empty file)
+++ cupsys/branches/cups-1.2-ubuntu/debian/patches/56_revert_svn_5438.dpatch	Tue Apr 25 17:49:13 2006
@@ -0,0 +1,158 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 56_revert_svn_5438.dpatch by  <martin.pitt at ubuntu.com>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: No description.
+
+ at DPATCH@
+diff -urNad cups-1.2-ubuntu~/scheduler/ipp.c cups-1.2-ubuntu/scheduler/ipp.c
+--- cups-1.2-ubuntu~/scheduler/ipp.c	2006-04-25 19:42:17.000000000 +0200
++++ cups-1.2-ubuntu/scheduler/ipp.c	2006-04-25 19:42:47.000000000 +0200
+@@ -5094,12 +5094,14 @@
+ get_devices(cupsd_client_t *con)	/* I - Client connection */
+ {
+   http_status_t		status;		/* Policy status */
++  int			i;		/* Looping var */
+   ipp_attribute_t	*limit,		/* Limit attribute */
+ 			*requested;	/* requested-attributes attribute */
+   char			command[1024],	/* cups-deviced command */
+ 			options[1024],	/* Options to pass to command */
+-			requested_str[256];
+-					/* String for requested attributes */
++			attrs[1024],	/* String for requested attributes */
++			*aptr;		/* Pointer into string */
++  int			alen;		/* Length of attribute value */
+ 
+ 
+   cupsdLogMessage(CUPSD_LOG_DEBUG2, "get_devices(%p[%d])", con, con->http.fd);
+@@ -5123,16 +5125,48 @@
+                                IPP_TAG_KEYWORD);
+ 
+   if (requested)
+-    url_encode_attr(requested, requested_str, sizeof(requested_str));
++  {
++    for (i = 0, aptr = attrs; i < requested->num_values; i ++)
++    {
++     /*
++      * Check that we have enough room...
++      */
++
++      alen = strlen(requested->values[i].string.text);
++      if (alen > (sizeof(attrs) - (aptr - attrs) - 2))
++        break;
++
++     /*
++      * Put commas between values...
++      */
++
++      if (i)
++        *aptr++ = ',';
++
++     /*
++      * Add the value to the end of the string...
++      */
++
++      strcpy(aptr, requested->values[i].string.text);
++      aptr += alen;
++    }
++
++   /*
++    * If we have more attribute names than will fit, default to "all"...
++    */
++
++    if (i < requested->num_values)
++      strcpy(attrs, "all");
++  }
+   else
+-    strlcpy(requested_str, "requested-attributes=all", sizeof(requested_str));
++    strcpy(attrs, "all");
+ 
+   snprintf(command, sizeof(command), "%s/daemon/cups-deviced", ServerBin);
+   snprintf(options, sizeof(options),
+-           "%d+%d+%d+%s",
++           "%d+%d+%d+requested-attributes=%s",
+            con->request->request.op.request_id,
+            limit ? limit->values[0].integer : 0, (int)User,
+-	   requested_str);
++	   attrs);
+ 
+   if (cupsdSendCommand(con, command, options, 1))
+   {
+@@ -5600,14 +5634,15 @@
+ get_ppds(cupsd_client_t *con)		/* I - Client connection */
+ {
+   http_status_t		status;		/* Policy status */
++  int			i;		/* Looping var */
+   ipp_attribute_t	*limit,		/* Limit attribute */
+ 			*make,		/* ppd-make attribute */
+ 			*requested;	/* requested-attributes attribute */
+   char			command[1024],	/* cups-deviced command */
+ 			options[1024],	/* Options to pass to command */
+-			requested_str[256],
+-					/* String for requested attributes */
+-			make_str[256];	/* Escaped ppd-make string */
++			attrs[1024],	/* String for requested attributes */
++			*aptr;		/* Pointer into string */
++  int			alen;		/* Length of attribute value */
+ 
+ 
+   cupsdLogMessage(CUPSD_LOG_DEBUG2, "get_ppds(%p[%d])", con, con->http.fd);
+@@ -5632,20 +5667,50 @@
+                                IPP_TAG_KEYWORD);
+ 
+   if (requested)
+-    url_encode_attr(requested, requested_str, sizeof(requested_str));
+-  else
+-    strlcpy(requested_str, "requested-attributes=all", sizeof(requested_str));
++  {
++    for (i = 0, aptr = attrs; i < requested->num_values; i ++)
++    {
++     /*
++      * Check that we have enough room...
++      */
+ 
+-  if (make)
+-    url_encode_attr(make, make_str, sizeof(make_str));
++      alen = strlen(requested->values[i].string.text);
++      if (alen > (sizeof(attrs) - (aptr - attrs) - 2))
++        break;
++
++     /*
++      * Put commas between values...
++      */
++
++      if (i)
++        *aptr++ = ',';
++
++     /*
++      * Add the value to the end of the string...
++      */
++
++      strcpy(aptr, requested->values[i].string.text);
++      aptr += alen;
++    }
++
++   /*
++    * If we have more attribute names than will fit, default to "all"...
++    */
++
++    if (i < requested->num_values)
++      strcpy(attrs, "all");
++  }
+   else
+-    make_str[0] = '\0';
++    strcpy(attrs, "all");
+ 
+   snprintf(command, sizeof(command), "%s/daemon/cups-driverd", ServerBin);
+-  snprintf(options, sizeof(options), "list+%d+%d+%s%s%s",
++  snprintf(options, sizeof(options),
++           "list+%d+%d+requested-attributes=%s%s%s",
+            con->request->request.op.request_id,
+            limit ? limit->values[0].integer : 0,
+-	   requested_str, make ? "%20" : "", make_str);
++	   attrs,
++	   make ? "%20ppd-make=" : "",
++	   make ? make->values[0].string.text : "");
+ 
+   if (cupsdSendCommand(con, command, options, 0))
+   {



More information about the Pkg-cups-devel mailing list