rev 4801 - in trunk/packages/kdelibs/debian: . patches

Christopher Martin chrsmrtn at costa.debian.org
Fri Oct 27 04:17:45 UTC 2006


Author: chrsmrtn
Date: 2006-10-27 04:17:44 +0000 (Fri, 27 Oct 2006)
New Revision: 4801

Added:
   trunk/packages/kdelibs/debian/patches/33_cups12_kprinter_fixes.diff
Modified:
   trunk/packages/kdelibs/debian/changelog
Log:
Add a new kprinter patch. PLEASE TEST, I HAVEN'T VERIFIED THAT IT WORKS.


Modified: trunk/packages/kdelibs/debian/changelog
===================================================================
--- trunk/packages/kdelibs/debian/changelog	2006-10-26 21:08:45 UTC (rev 4800)
+++ trunk/packages/kdelibs/debian/changelog	2006-10-27 04:17:44 UTC (rev 4801)
@@ -1,16 +1,25 @@
 kdelibs (4:3.5.5a.dfsg.1-3) UNRELEASED; urgency=low
 
   * Patch: 41_x_kde_getactionmenu_no_timeout.diff
-      Do not time out when waiting for the reply for the X-KDE-GetActionMenu
-      DCOP call. DCOP protocol is synchronouos by design and a reply for the
-      timed out call (i.e. garbage) still arrives and might be falsely returned
-      as a valid reply for the subsequent DCOP call on the same connection. The
-      application currently known to be badly hurt by this is kdesvn and its
-      konqueror service menu integration. Its X-KDE-GetActionMenu might take
-      longer than current 100 milisecond timeout to complete. As a result
-      then, a late reply will "pollute" a main DCOP connection of the client
-      application (e.g. konqueror) causing further DCOP failures. Closes: #348411
+    Do not time out when waiting for the reply for the X-KDE-GetActionMenu
+    DCOP call. DCOP protocol is synchronouos by design and a reply for the
+    timed out call (i.e. garbage) still arrives and might be falsely returned
+    as a valid reply for the subsequent DCOP call on the same connection. The
+    application currently known to be badly hurt by this is kdesvn and its
+    konqueror service menu integration. Its X-KDE-GetActionMenu might take
+    longer than current 100 milisecond timeout to complete. As a result
+    then, a late reply will "pollute" a main DCOP connection of the client
+    application (e.g. konqueror) causing further DCOP failures.
+    (Closes: #348411)
 
+  * Add 33_cups12_kprinter_fixes.diff, an unmerged patch in upstream's BTS
+    at http://bugs.kde.org/115891, which should fix the remaining problems
+    people are encountering when attempting to print. This supersedes
+    several of our own kprinter patches. (Closes: #395383)
+
+    !!! Please test the above changes. I don't suffer from the reported
+    problems, so I don't really know if it fixes them. !!!
+
  -- Debian Qt/KDE Maintainers <debian-qt-kde at lists.debian.org>  Thu, 26 Oct 2006 10:44:35 +0300
 
 kdelibs (4:3.5.5a.dfsg.1-2) unstable; urgency=high

Added: trunk/packages/kdelibs/debian/patches/33_cups12_kprinter_fixes.diff
===================================================================
--- trunk/packages/kdelibs/debian/patches/33_cups12_kprinter_fixes.diff	                        (rev 0)
+++ trunk/packages/kdelibs/debian/patches/33_cups12_kprinter_fixes.diff	2006-10-27 04:17:44 UTC (rev 4801)
@@ -0,0 +1,56 @@
+--- kde.orig/kdeprint/cups/ipprequest.cpp
++++ kde.patched/kdeprint/cups/ipprequest.cpp
+@@ -329,6 +329,10 @@
+ 		dumpRequest(request_, true);
+ 	}
+ 
++	/* No printers found */
++	if ( request_ && request_->request.status.status_code == 0x406 )
++		return true;
++
+ 	if (!request_ || request_->state == IPP_ERROR || (request_->request.status.status_code & 0x0F00))
+ 		return false;
+ 
+--- kde.orig/kdeprint/cups/kmcupsmanager.cpp
++++ kde.patched/kdeprint/cups/kmcupsmanager.cpp
+@@ -61,7 +61,7 @@
+ #define ppdi18n(s)	i18n(QString::fromLocal8Bit(s).utf8())
+ 
+ void extractMaticData(QString& buf, const QString& filename);
+-QString printerURI(KMPrinter *p, bool useExistingURI = false);
++QString printerURI(KMPrinter *p, bool useExistingURI);
+ QString downloadDriver(KMPrinter *p);
+ 
+ static int trials = 5;
+@@ -218,7 +218,7 @@
+ 	QString		uri;
+ 
+ 	req.setOperation(state);
+-	uri = printerURI(p);
++	uri = printerURI(p, true);
+ 	req.addURI(IPP_TAG_OPERATION,"printer-uri",uri);
+ 	if (req.doRequest("/admin/"))
+ 		return true;
+@@ -1033,8 +1033,20 @@
+ 	QString	uri;
+ 	if (use && !p->uri().isEmpty())
+ 		uri = p->uri().prettyURL();
+-	else
+-		uri = QString("ipp://%1/%3/%2").arg(CupsInfos::self()->hostaddr()).arg(p->printerName()).arg((p->isClass(false) ? "classes" : "printers"));
++	else {
++		int port = CupsInfos::self()->port();
++	 	QString host = CupsInfos::self()->host();
++#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2
++		// Resolve potential domain sockets and other potential "weired" hostnames
++		http_t *http = httpConnect(host.latin1(), port);
++		if (http) {
++			char buf[256];
++			host = QString::fromLatin1(httpGetHostname(http, buf, sizeof(buf)));
++			httpClose(http);
++		}
++#endif
++	uri = QString("ipp://%1:%2/%4/%3").arg(host).arg(port).arg(p->printerName()).arg((p->isClass(false) ? "classes" : "printers"));
++	}
+ 	return uri;
+ }
+ 




More information about the pkg-kde-commits mailing list