Some fixes for the AvahiClient callback (bug #672143).

This commit is contained in:
Tim Waugh 2011-01-25 17:40:34 +00:00
parent 852d6ef4ae
commit 04a43d9470
2 changed files with 76 additions and 72 deletions

View File

@ -1,6 +1,6 @@
diff -up cups-1.4.5/backend/dnssd.c.avahi cups-1.4.5/backend/dnssd.c
--- cups-1.4.5/backend/dnssd.c.avahi 2010-12-31 10:31:00.333635888 +0000
+++ cups-1.4.5/backend/dnssd.c 2010-12-31 10:31:07.791916045 +0000
diff -up cups-1.4.6/backend/dnssd.c.avahi cups-1.4.6/backend/dnssd.c
--- cups-1.4.6/backend/dnssd.c.avahi 2011-01-25 13:26:16.607114570 +0000
+++ cups-1.4.6/backend/dnssd.c 2011-01-25 13:26:16.633115058 +0000
@@ -15,14 +15,21 @@
*
* Contents:
@ -824,9 +824,9 @@ diff -up cups-1.4.5/backend/dnssd.c.avahi cups-1.4.5/backend/dnssd.c
/*
* 'sigterm_handler()' - Handle termination signals...
*/
diff -up cups-1.4.5/config.h.in.avahi cups-1.4.5/config.h.in
--- cups-1.4.5/config.h.in.avahi 2010-08-13 05:11:46.000000000 +0100
+++ cups-1.4.5/config.h.in 2010-12-31 10:31:07.793916122 +0000
diff -up cups-1.4.6/config.h.in.avahi cups-1.4.6/config.h.in
--- cups-1.4.6/config.h.in.avahi 2010-08-13 05:11:46.000000000 +0100
+++ cups-1.4.6/config.h.in 2011-01-25 13:26:16.635115097 +0000
@@ -344,6 +344,13 @@
@ -841,9 +841,9 @@ diff -up cups-1.4.5/config.h.in.avahi cups-1.4.5/config.h.in
* Do we have <sys/ioctl.h>?
*/
diff -up cups-1.4.5/config-scripts/cups-dnssd.m4.avahi cups-1.4.5/config-scripts/cups-dnssd.m4
--- cups-1.4.5/config-scripts/cups-dnssd.m4.avahi 2009-08-28 23:54:34.000000000 +0100
+++ cups-1.4.5/config-scripts/cups-dnssd.m4 2010-12-31 10:31:07.792916086 +0000
diff -up cups-1.4.6/config-scripts/cups-dnssd.m4.avahi cups-1.4.6/config-scripts/cups-dnssd.m4
--- cups-1.4.6/config-scripts/cups-dnssd.m4.avahi 2009-08-28 23:54:34.000000000 +0100
+++ cups-1.4.6/config-scripts/cups-dnssd.m4 2011-01-25 13:26:16.636115116 +0000
@@ -27,6 +27,21 @@ AC_ARG_WITH(dnssd-includes, [ --with-dn
DNSSDLIBS=""
DNSSD_BACKEND=""
@ -866,9 +866,9 @@ diff -up cups-1.4.5/config-scripts/cups-dnssd.m4.avahi cups-1.4.5/config-scripts
if test x$enable_dnssd != xno; then
AC_CHECK_HEADER(dns_sd.h, [
case "$uname" in
diff -up cups-1.4.5/cups/http-support.c.avahi cups-1.4.5/cups/http-support.c
--- cups-1.4.5/cups/http-support.c.avahi 2010-10-01 23:40:38.000000000 +0100
+++ cups-1.4.5/cups/http-support.c 2010-12-31 10:31:07.795916189 +0000
diff -up cups-1.4.6/cups/http-support.c.avahi cups-1.4.6/cups/http-support.c
--- cups-1.4.6/cups/http-support.c.avahi 2010-10-01 23:40:38.000000000 +0100
+++ cups-1.4.6/cups/http-support.c 2011-01-25 13:26:16.638115152 +0000
@@ -41,6 +41,10 @@
* http_copy_decode() - Copy and decode a URI.
* http_copy_encode() - Copy and encode a URI.
@ -1136,9 +1136,9 @@ diff -up cups-1.4.5/cups/http-support.c.avahi cups-1.4.5/cups/http-support.c
/*
* End of "$Id: http-support.c 9322 2010-10-01 22:40:38Z mike $".
*/
diff -up cups-1.4.5/scheduler/avahi.c.avahi cups-1.4.5/scheduler/avahi.c
--- cups-1.4.5/scheduler/avahi.c.avahi 2010-12-31 10:31:07.801916421 +0000
+++ cups-1.4.5/scheduler/avahi.c 2010-12-31 10:31:07.801916421 +0000
diff -up cups-1.4.6/scheduler/avahi.c.avahi cups-1.4.6/scheduler/avahi.c
--- cups-1.4.6/scheduler/avahi.c.avahi 2011-01-25 13:26:16.640115190 +0000
+++ cups-1.4.6/scheduler/avahi.c 2011-01-25 13:26:16.640115190 +0000
@@ -0,0 +1,443 @@
+/*
+ * "$Id$"
@ -1583,9 +1583,9 @@ diff -up cups-1.4.5/scheduler/avahi.c.avahi cups-1.4.5/scheduler/avahi.c
+/*
+ * End of "$Id$".
+ */
diff -up cups-1.4.5/scheduler/avahi.h.avahi cups-1.4.5/scheduler/avahi.h
--- cups-1.4.5/scheduler/avahi.h.avahi 2010-12-31 10:31:07.802916458 +0000
+++ cups-1.4.5/scheduler/avahi.h 2010-12-31 10:31:07.802916458 +0000
diff -up cups-1.4.6/scheduler/avahi.h.avahi cups-1.4.6/scheduler/avahi.h
--- cups-1.4.6/scheduler/avahi.h.avahi 2011-01-25 13:26:16.640115190 +0000
+++ cups-1.4.6/scheduler/avahi.h 2011-01-25 13:26:16.641115209 +0000
@@ -0,0 +1,49 @@
+/*
+ * "$Id$"
@ -1636,9 +1636,9 @@ diff -up cups-1.4.5/scheduler/avahi.h.avahi cups-1.4.5/scheduler/avahi.h
+/*
+ * End of "$Id$".
+ */
diff -up cups-1.4.5/scheduler/cupsd.h.avahi cups-1.4.5/scheduler/cupsd.h
--- cups-1.4.5/scheduler/cupsd.h.avahi 2010-09-21 23:34:57.000000000 +0100
+++ cups-1.4.5/scheduler/cupsd.h 2010-12-31 10:31:07.803916494 +0000
diff -up cups-1.4.6/scheduler/cupsd.h.avahi cups-1.4.6/scheduler/cupsd.h
--- cups-1.4.6/scheduler/cupsd.h.avahi 2010-09-21 23:34:57.000000000 +0100
+++ cups-1.4.6/scheduler/cupsd.h 2011-01-25 13:26:16.641115209 +0000
@@ -147,6 +147,15 @@ extern const char *cups_hstrerror(int);
typedef void (*cupsd_selfunc_t)(void *data);
@ -1684,9 +1684,9 @@ diff -up cups-1.4.5/scheduler/cupsd.h.avahi cups-1.4.5/scheduler/cupsd.h
extern int cupsdRemoveFile(const char *filename);
diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
--- cups-1.4.5/scheduler/dirsvc.c.avahi 2010-12-31 10:31:00.255632958 +0000
+++ cups-1.4.5/scheduler/dirsvc.c 2010-12-31 10:31:07.808916680 +0000
diff -up cups-1.4.6/scheduler/dirsvc.c.avahi cups-1.4.6/scheduler/dirsvc.c
--- cups-1.4.6/scheduler/dirsvc.c.avahi 2011-01-25 13:26:16.534113189 +0000
+++ cups-1.4.6/scheduler/dirsvc.c 2011-01-25 17:39:15.062315327 +0000
@@ -27,6 +27,7 @@
* ldap_connect() - Start new LDAP connection
* ldap_reconnect() - Reconnect to LDAP Server
@ -1785,7 +1785,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
}
@@ -1411,6 +1433,24 @@ ldap_disconnect(LDAP *ld) /* I - LDAP h
@@ -1411,6 +1433,23 @@ ldap_disconnect(LDAP *ld) /* I - LDAP h
}
#endif /* HAVE_LDAP */
@ -1796,8 +1796,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
+
+void
+cupsdStartAvahiClient(void) {
+ if ((!AvahiCupsClient) &&
+ (!AvahiCupsClientConnecting || !(*AvahiCupsClientConnecting)))
+ if (!AvahiCupsClient && !AvahiCupsClientConnecting)
+ {
+ if (!AvahiCupsPollHandle)
+ AvahiCupsPollHandle = avahi_cups_poll_new ();
@ -1810,7 +1809,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* 'cupsdStartBrowsing()' - Start sending and receiving broadcast information.
@@ -1535,13 +1575,16 @@ cupsdStartBrowsing(void)
@@ -1535,13 +1574,16 @@ cupsdStartBrowsing(void)
else
BrowseSocket = -1;
@ -1828,7 +1827,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* First create a "master" connection for all registrations...
*/
@@ -1566,6 +1609,7 @@ cupsdStartBrowsing(void)
@@ -1566,6 +1608,7 @@ cupsdStartBrowsing(void)
fcntl(fd, F_SETFD, fcntl(fd, F_GETFD) | FD_CLOEXEC);
cupsdAddSelect(fd, (cupsd_selfunc_t)dnssdUpdate, NULL, NULL);
@ -1836,7 +1835,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* Then get the port we use for registrations. If we are not listening
@@ -1607,9 +1651,16 @@ cupsdStartBrowsing(void)
@@ -1607,9 +1650,16 @@ cupsdStartBrowsing(void)
*/
cupsdUpdateDNSSDName();
@ -1854,7 +1853,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
#ifdef HAVE_LIBSLP
if ((BrowseLocalProtocols | BrowseRemoteProtocols) & BROWSE_SLP)
@@ -1835,10 +1886,10 @@ cupsdStopBrowsing(void)
@@ -1835,10 +1885,10 @@ cupsdStopBrowsing(void)
BrowseSocket = -1;
}
@ -1868,7 +1867,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
#ifdef HAVE_LIBSLP
if (((BrowseLocalProtocols | BrowseRemoteProtocols) & BROWSE_SLP) &&
@@ -1903,7 +1954,7 @@ cupsdStopPolling(void)
@@ -1903,7 +1953,7 @@ cupsdStopPolling(void)
}
@ -1877,7 +1876,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* 'cupsdUpdateDNSSDName()' - Update the computer name we use for browsing...
*/
@@ -1911,7 +1962,12 @@ cupsdStopPolling(void)
@@ -1911,7 +1961,12 @@ cupsdStopPolling(void)
void
cupsdUpdateDNSSDName(void)
{
@ -1890,7 +1889,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
char webif[1024]; /* Web interface share name */
#ifdef HAVE_COREFOUNDATION_H
SCDynamicStoreRef sc; /* Context for dynamic store */
@@ -2043,6 +2099,7 @@ cupsdUpdateDNSSDName(void)
@@ -2043,6 +2098,7 @@ cupsdUpdateDNSSDName(void)
else
strlcpy(webif, "CUPS Web Interface", sizeof(webif));
@ -1898,7 +1897,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
if (WebIFRef)
DNSServiceRefDeallocate(WebIFRef);
@@ -2055,6 +2112,42 @@ cupsdUpdateDNSSDName(void)
@@ -2055,6 +2111,42 @@ cupsdUpdateDNSSDName(void)
NULL)) != kDNSServiceErr_NoError)
cupsdLogMessage(CUPSD_LOG_ERROR,
"DNS-SD web interface registration failed: %d", error);
@ -1941,7 +1940,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
}
}
#endif /* HAVE_DNSSD */
@@ -2300,162 +2393,7 @@ dequote(char *d, /* I - Destinat
@@ -2300,162 +2392,7 @@ dequote(char *d, /* I - Destinat
}
@ -2105,7 +2104,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* 'dnssdComparePrinters()' - Compare the registered names of two printers.
*/
@@ -2464,7 +2402,16 @@ static int /* O - Result of compariso
@@ -2464,7 +2401,16 @@ static int /* O - Result of compariso
dnssdComparePrinters(cupsd_printer_t *a,/* I - First printer */
cupsd_printer_t *b)/* I - Second printer */
{
@ -2123,7 +2122,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
}
@@ -2479,6 +2426,10 @@ dnssdDeregisterPrinter(
@@ -2479,6 +2425,10 @@ dnssdDeregisterPrinter(
{
cupsdLogMessage(CUPSD_LOG_DEBUG2, "dnssdDeregisterPrinter(%s)", p->name);
@ -2134,7 +2133,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* Closing the socket deregisters the service
*/
@@ -2514,6 +2465,23 @@ dnssdDeregisterPrinter(
@@ -2514,6 +2464,23 @@ dnssdDeregisterPrinter(
free(p->printer_txt);
p->printer_txt = NULL;
}
@ -2158,7 +2157,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* Remove the printer from the array of DNS-SD printers, then clear the
@@ -2526,133 +2494,46 @@ dnssdDeregisterPrinter(
@@ -2526,133 +2493,46 @@ dnssdDeregisterPrinter(
/*
@ -2324,7 +2323,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
*/
if (!p->shared)
@@ -2694,6 +2575,7 @@ dnssdRegisterPrinter(cupsd_printer_t *p)
@@ -2694,6 +2574,7 @@ dnssdRegisterPrinter(cupsd_printer_t *p)
* Register IPP and (optionally) LPD...
*/
@ -2332,7 +2331,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
ipp_len = 0; /* anti-compiler-warning-code */
ipp_txt = dnssdBuildTxtRecord(&ipp_len, p, 0);
@@ -2860,6 +2742,146 @@ dnssdRegisterPrinter(cupsd_printer_t *p)
@@ -2860,6 +2741,146 @@ dnssdRegisterPrinter(cupsd_printer_t *p)
if (printer_txt)
free(printer_txt);
}
@ -2479,7 +2478,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
}
@@ -2872,6 +2894,10 @@ dnssdStop(void)
@@ -2872,6 +2893,10 @@ dnssdStop(void)
{
cupsd_printer_t *p; /* Current printer */
@ -2490,7 +2489,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* De-register the individual printers
@@ -2882,6 +2908,7 @@ dnssdStop(void)
@@ -2882,6 +2907,7 @@ dnssdStop(void)
p = (cupsd_printer_t *)cupsArrayNext(Printers))
dnssdDeregisterPrinter(p);
@ -2498,7 +2497,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* Shutdown the rest of the service refs...
*/
@@ -2902,6 +2929,7 @@ dnssdStop(void)
@@ -2902,6 +2928,7 @@ dnssdStop(void)
DNSServiceRefDeallocate(DNSSDRef);
DNSSDRef = NULL;
@ -2506,7 +2505,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
cupsArrayDelete(DNSSDPrinters);
DNSSDPrinters = NULL;
@@ -2911,6 +2939,272 @@ dnssdStop(void)
@@ -2911,6 +2938,272 @@ dnssdStop(void)
/*
@ -2779,7 +2778,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
* 'dnssdUpdate()' - Handle DNS-SD queries.
*/
@@ -2931,6 +3225,144 @@ dnssdUpdate(void)
@@ -2931,6 +3224,146 @@ dnssdUpdate(void)
#endif /* HAVE_DNSSD */
@ -2874,7 +2873,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
+ * Avahi client started successfully.
+ */
+ AvahiCupsClient = client;
+ AvahiCupsClientConnecting = NULL;
+ AvahiCupsClientConnecting = 0;
+ cupsdLogMessage (CUPSD_LOG_DEBUG, "Avahi client started");
+
+ cupsdUpdateDNSSDName ();
@ -2893,7 +2892,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
+ /*
+ * No Avahi daemon, client is waiting.
+ */
+ AvahiCupsClientConnecting = &client;
+ AvahiCupsClientConnecting = 1;
+ cupsdLogMessage (CUPSD_LOG_DEBUG, "Avahi client connecting");
+ break;
+
@ -2901,15 +2900,17 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
+ /*
+ * Avahi client failed, close it to allow a clean restart.
+ */
+ cupsdLogMessage (CUPSD_LOG_ERROR, "Avahi client failed, closing client to allow a clean restart");
+ cupsdLogMessage (CUPSD_LOG_ERROR,
+ "Avahi client failed, "
+ "closing client to allow a clean restart");
+
+ for (printer = (cupsd_printer_t *)cupsArrayFirst(Printers);
+ printer;
+ printer = (cupsd_printer_t *)cupsArrayNext(Printers))
+ dnssdDeregisterPrinter (printer);
+
+ avahi_client_free(AvahiCupsClient);
+ AvahiCupsClientConnecting = NULL;
+ avahi_client_free(client);
+ AvahiCupsClientConnecting = 0;
+ AvahiCupsClient = NULL;
+
+ break;
@ -2924,9 +2925,9 @@ diff -up cups-1.4.5/scheduler/dirsvc.c.avahi cups-1.4.5/scheduler/dirsvc.c
/*
* 'get_auth_info_required()' - Get the auth-info-required value to advertise.
*/
diff -up cups-1.4.5/scheduler/dirsvc.h.avahi cups-1.4.5/scheduler/dirsvc.h
--- cups-1.4.5/scheduler/dirsvc.h.avahi 2009-05-14 18:54:37.000000000 +0100
+++ cups-1.4.5/scheduler/dirsvc.h 2010-12-31 10:31:07.811916792 +0000
diff -up cups-1.4.6/scheduler/dirsvc.h.avahi cups-1.4.6/scheduler/dirsvc.h
--- cups-1.4.6/scheduler/dirsvc.h.avahi 2009-05-14 18:54:37.000000000 +0100
+++ cups-1.4.6/scheduler/dirsvc.h 2011-01-25 17:39:15.063315332 +0000
@@ -32,6 +32,10 @@
# endif /* HAVE_LDAP_SSL_H */
#endif /* HAVE_LDAP */
@ -2973,7 +2974,7 @@ diff -up cups-1.4.5/scheduler/dirsvc.h.avahi cups-1.4.5/scheduler/dirsvc.h
+ /* AvahiCupsPoll object */
+VAR AvahiClient *AvahiCupsClient VALUE(NULL);
+ /* AvahiClient object */
+VAR AvahiClient **AvahiCupsClientConnecting VALUE(NULL);
+VAR int AvahiCupsClientConnecting VALUE(0);
+ /* AvahiClient object (waiting) */
+VAR AvahiEntryGroup *AvahiWebIFGroup VALUE(NULL);
+ /* Web interface entry group */
@ -2999,9 +3000,9 @@ diff -up cups-1.4.5/scheduler/dirsvc.h.avahi cups-1.4.5/scheduler/dirsvc.h
#ifdef HAVE_LDAP
extern void cupsdUpdateLDAPBrowse(void);
#endif /* HAVE_LDAP */
diff -up cups-1.4.5/scheduler/main.c.avahi cups-1.4.5/scheduler/main.c
--- cups-1.4.5/scheduler/main.c.avahi 2010-12-31 10:31:00.209631230 +0000
+++ cups-1.4.5/scheduler/main.c 2010-12-31 10:31:07.813916862 +0000
diff -up cups-1.4.6/scheduler/main.c.avahi cups-1.4.6/scheduler/main.c
--- cups-1.4.6/scheduler/main.c.avahi 2011-01-25 13:26:16.487112302 +0000
+++ cups-1.4.6/scheduler/main.c 2011-01-25 13:26:16.650115377 +0000
@@ -135,6 +135,10 @@ main(int argc, /* I - Number of comm
cupsd_listener_t *lis; /* Current listener */
time_t current_time, /* Current time */
@ -3107,9 +3108,9 @@ diff -up cups-1.4.5/scheduler/main.c.avahi cups-1.4.5/scheduler/main.c
/*
* Check whether we are accepting new connections...
*/
diff -up cups-1.4.5/scheduler/Makefile.avahi cups-1.4.5/scheduler/Makefile
--- cups-1.4.5/scheduler/Makefile.avahi 2010-12-31 10:31:00.313635137 +0000
+++ cups-1.4.5/scheduler/Makefile 2010-12-31 10:31:07.796916222 +0000
diff -up cups-1.4.6/scheduler/Makefile.avahi cups-1.4.6/scheduler/Makefile
--- cups-1.4.6/scheduler/Makefile.avahi 2011-01-25 13:26:16.591114269 +0000
+++ cups-1.4.6/scheduler/Makefile 2011-01-25 13:26:16.657115510 +0000
@@ -17,6 +17,7 @@ include ../Makedefs
CUPSDOBJS = \
@ -3128,9 +3129,9 @@ diff -up cups-1.4.5/scheduler/Makefile.avahi cups-1.4.5/scheduler/Makefile
LIBOBJS = \
filter.o \
mime.o \
diff -up cups-1.4.5/scheduler/printers.c.avahi cups-1.4.5/scheduler/printers.c
--- cups-1.4.5/scheduler/printers.c.avahi 2010-12-31 10:31:00.355636715 +0000
+++ cups-1.4.5/scheduler/printers.c 2010-12-31 10:31:07.822917201 +0000
diff -up cups-1.4.6/scheduler/printers.c.avahi cups-1.4.6/scheduler/printers.c
--- cups-1.4.6/scheduler/printers.c.avahi 2011-01-25 13:26:16.628114966 +0000
+++ cups-1.4.6/scheduler/printers.c 2011-01-25 13:26:16.659115546 +0000
@@ -929,10 +929,10 @@ cupsdDeletePrinter(
cupsdClearString(&p->alert);
cupsdClearString(&p->alert_description);
@ -3199,9 +3200,9 @@ diff -up cups-1.4.5/scheduler/printers.c.avahi cups-1.4.5/scheduler/printers.c
if (ppdFindAttr(ppd, "APRemoteQueueID", NULL))
p->type |= CUPS_PRINTER_REMOTE;
diff -up cups-1.4.5/scheduler/printers.h.avahi cups-1.4.5/scheduler/printers.h
--- cups-1.4.5/scheduler/printers.h.avahi 2010-03-30 23:07:33.000000000 +0100
+++ cups-1.4.5/scheduler/printers.h 2010-12-31 10:31:07.828917428 +0000
diff -up cups-1.4.6/scheduler/printers.h.avahi cups-1.4.6/scheduler/printers.h
--- cups-1.4.6/scheduler/printers.h.avahi 2010-03-30 23:07:33.000000000 +0100
+++ cups-1.4.6/scheduler/printers.h 2011-01-25 13:26:16.665115661 +0000
@@ -16,6 +16,9 @@
#ifdef HAVE_DNSSD
# include <dns_sd.h>
@ -3241,9 +3242,9 @@ diff -up cups-1.4.5/scheduler/printers.h.avahi cups-1.4.5/scheduler/printers.h
} cupsd_printer_t;
diff -up cups-1.4.5/scheduler/timeout.c.avahi cups-1.4.5/scheduler/timeout.c
--- cups-1.4.5/scheduler/timeout.c.avahi 2010-12-31 10:31:07.831917542 +0000
+++ cups-1.4.5/scheduler/timeout.c 2010-12-31 10:31:07.831917542 +0000
diff -up cups-1.4.6/scheduler/timeout.c.avahi cups-1.4.6/scheduler/timeout.c
--- cups-1.4.6/scheduler/timeout.c.avahi 2011-01-25 13:26:16.668115715 +0000
+++ cups-1.4.6/scheduler/timeout.c 2011-01-25 13:26:16.668115715 +0000
@@ -0,0 +1,195 @@
+/*
+ * "$Id$"

View File

@ -8,7 +8,7 @@
Summary: Common Unix Printing System
Name: cups
Version: 1.4.6
Release: 6%{?dist}
Release: 7%{?dist}
License: GPLv2
Group: System Environment/Daemons
Source: http://ftp.easysw.com/pub/cups/%{version}/cups-%{version}-source.tar.bz2
@ -603,6 +603,9 @@ rm -rf $RPM_BUILD_ROOT
%{php_extdir}/phpcups.so
%changelog
* Tue Jan 25 2011 Tim Waugh <twaugh@redhat.com> 1:1.4.6-7
- Some fixes for the AvahiClient callback (bug #672143).
* Tue Jan 18 2011 Tim Waugh <twaugh@redhat.com> 1:1.4.6-6
- Don't use --enable-pie configure option as it has been removed and
is now assumed. See STR #3691.