Skip to content

Commit

Permalink
Merge changes from CUPS 1.6svn-r10112.
Browse files Browse the repository at this point in the history
git-svn-id: svn+ssh://src.apple.com/svn/cups/easysw/current@3486 a1ca3aef-8c08-0410-bb20-df032aa958be
  • Loading branch information
msweet committed Nov 8, 2011
1 parent d7225fc commit a2326b5
Show file tree
Hide file tree
Showing 94 changed files with 9,182 additions and 11,018 deletions.
14 changes: 13 additions & 1 deletion CHANGES-1.5.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,19 @@ CHANGES-1.5.txt

CHANGES IN CUPS V1.5.1

- Documentation updates (STR #3885, STR #3946)
- Documentation updates (STR #3885, STR #3946, STR #3969)
- Build fixes (STR #3956)
- Group quota ACLs did not work with Kerberos (STR #3972)
- The IPP backend did not retry when a printer responded with
client-error-not-possible (STR #3963)
- PostScript PPDs with filters used the wrong command filter (STR #3973)
- The scheduler incorrectly used free() on a POSIX ACL value, which
could cause a crash (STR #3970)
- PPD files using the MacStandard encoding did not work.
- The web interface did not work on some platforms (STR #3902)
- The lpstat command would crash when then "-u" option was used by a
non-administrator (STR #3953)
- Japanese supply level reporting did not always work.
- The DBUS notifier could crash (STR #3947)
- Relaxed some of the page size checks in cupstestppd.
- The ipptool program now reports attributes that are repeated within
Expand Down
5 changes: 3 additions & 2 deletions CHANGES-IPPTOOL.txt
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
CHANGES-IPPTOOL.txt - 2011-10-04
CHANGES-IPPTOOL.txt - 2011-10-05
--------------------------------

This file provides a list of changes to the ipptool binary distribution posted
on cups.org.


2011-10-04
2011-10-05

- Fixed a crasher bug that showed up on Windows.
- The IPP/1.1 test would hang if the initial Print-Job test failed.
- Fixed a typo in the IPP/2.0 test.


Expand Down
9 changes: 8 additions & 1 deletion CHANGES.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,15 @@
CHANGES.txt - 1.6b1 - 2011-08-30
CHANGES.txt - 1.6b1 - 2011-11-03
--------------------------------

CHANGES IN CUPS V1.6b1

- CUPS no longer supports automatic remote printers or implicit classes
via the CUPS, LDAP, or SLP protocols (STR #3922, STR #3923)
- The PPD APIs are now deprecated and will be removed in a future
version of CUPS (STR #3927)
- The default IPP version for requests is now 2.0 (STR #3929)
- The IPP APIs no longer expose the ipp_t or ipp_attribute_t structures
and instead provide accessor functions (STR #3928)
- The scheduler will no longer run programs with group write permission.
- The PHP module has been removed (STR #3932)
- The bannertops, commandtoescpx, commandtopclx, imagetops,
Expand Down
2 changes: 0 additions & 2 deletions Makedefs.in
Original file line number Diff line number Diff line change
Expand Up @@ -82,10 +82,8 @@ LIBCUPSIMAGE = @LIBCUPSIMAGE@
LIBCUPSMIME = @LIBCUPSMIME@
LIBCUPSPPDC = @LIBCUPSPPDC@
LIBCUPSSTATIC = @LIBCUPSSTATIC@
LIBLDAP = @LIBLDAP@
LIBMALLOC = @LIBMALLOC@
LIBPAPER = @LIBPAPER@
LIBSLP = @LIBSLP@
LIBGSSAPI = @LIBGSSAPI@
LIBUSB = @LIBUSB@
LIBWRAP = @LIBWRAP@
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -246,13 +246,13 @@ debugcheck: all unittests
#

apihelp:
for dir in cgi-bin cups filter driver ppdc scheduler; do\
for dir in cgi-bin cups filter ppdc scheduler; do\
echo Generating API help in $$dir... ;\
(cd $$dir; $(MAKE) $(MFLAGS) apihelp) || exit 1;\
done

framedhelp:
for dir in cgi-bin cups filter driver ppdc scheduler; do\
for dir in cgi-bin cups filter ppdc scheduler; do\
echo Generating framed API help in $$dir... ;\
(cd $$dir; $(MAKE) $(MFLAGS) framedhelp) || exit 1;\
done
Expand Down
1 change: 1 addition & 0 deletions backend/backend-private.h
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,7 @@ extern "C" {
#define CUPS_TC_csUTF32 1017
#define CUPS_TC_csUTF32BE 1018
#define CUPS_TC_csUTF32LE 1019
#define CUPS_TC_csWindows31J 2024


/*
Expand Down
7 changes: 6 additions & 1 deletion backend/ipp.c
Original file line number Diff line number Diff line change
Expand Up @@ -1393,6 +1393,7 @@ main(int argc, /* I - Number of command-line args */
break;

if (ipp_status == IPP_SERVICE_UNAVAILABLE ||
ipp_status == IPP_NOT_POSSIBLE ||
ipp_status == IPP_PRINTER_BUSY)
{
_cupsLangPrintFilter(stderr, "INFO", _("The printer is busy."));
Expand Down Expand Up @@ -1550,6 +1551,7 @@ main(int argc, /* I - Number of command-line args */
copies_remaining --;
}
else if (ipp_status == IPP_SERVICE_UNAVAILABLE ||
ipp_status == IPP_NOT_POSSIBLE ||
ipp_status == IPP_PRINTER_BUSY)
continue;
else
Expand Down Expand Up @@ -1622,6 +1624,7 @@ main(int argc, /* I - Number of command-line args */
if (ipp_status > IPP_OK_CONFLICT)
{
if (ipp_status != IPP_SERVICE_UNAVAILABLE &&
ipp_status != IPP_NOT_POSSIBLE &&
ipp_status != IPP_PRINTER_BUSY)
{
ippDelete(response);
Expand Down Expand Up @@ -1669,7 +1672,9 @@ main(int argc, /* I - Number of command-line args */
break;
}
}
else
else if (ipp_status != IPP_SERVICE_UNAVAILABLE &&
ipp_status != IPP_NOT_POSSIBLE &&
ipp_status != IPP_PRINTER_BUSY)
{
/*
* If the printer does not return a job-state attribute, it does not
Expand Down
1 change: 1 addition & 0 deletions backend/snmp-supplies.c
Original file line number Diff line number Diff line change
Expand Up @@ -801,6 +801,7 @@ backend_walk_cb(cups_snmp_t *packet, /* I - SNMP packet */
break;

case CUPS_TC_csShiftJIS :
case CUPS_TC_csWindows31J : /* Close enough for our purposes */
cupsCharsetToUTF8((cups_utf8_t *)supplies[i - 1].name,
(char *)packet->object_value.string.bytes,
sizeof(supplies[0].name), CUPS_JIS_X0213);
Expand Down
153 changes: 6 additions & 147 deletions cgi-bin/admin.c
Original file line number Diff line number Diff line change
Expand Up @@ -586,8 +586,7 @@ do_am_class(http_t *http, /* I - HTTP connection */
ippAddInteger(request, IPP_TAG_OPERATION, IPP_TAG_ENUM, "printer-type",
CUPS_PRINTER_LOCAL);
ippAddInteger(request, IPP_TAG_OPERATION, IPP_TAG_ENUM, "printer-type-mask",
CUPS_PRINTER_CLASS | CUPS_PRINTER_REMOTE |
CUPS_PRINTER_IMPLICIT);
CUPS_PRINTER_CLASS | CUPS_PRINTER_REMOTE);

/*
* Do the request and get back a response...
Expand Down Expand Up @@ -1560,8 +1559,6 @@ do_config_server(http_t *http) /* I - HTTP connection */
const char *debug_logging, /* DEBUG_LOGGING value */
*remote_admin, /* REMOTE_ADMIN value */
*remote_any, /* REMOTE_ANY value */
*remote_printers,
/* REMOTE_PRINTERS value */
*share_printers,/* SHARE_PRINTERS value */
*user_cancel_any,
/* USER_CANCEL_ANY value */
Expand All @@ -1577,10 +1574,6 @@ do_config_server(http_t *http) /* I - HTTP connection */
/* MaxJobs value */
*max_log_size = NULL;
/* MaxLogSize value */
char local_protocols[255],
/* BrowseLocalProtocols */
remote_protocols[255];
/* BrowseRemoteProtocols */
const char *current_browse_web_if,
/* BrowseWebIF value */
*current_preserve_job_history,
Expand All @@ -1591,12 +1584,8 @@ do_config_server(http_t *http) /* I - HTTP connection */
/* MaxClients value */
*current_max_jobs,
/* MaxJobs value */
*current_max_log_size,
*current_max_log_size;
/* MaxLogSize value */
*current_local_protocols,
/* BrowseLocalProtocols */
*current_remote_protocols;
/* BrowseRemoteProtocols */
#ifdef HAVE_GSSAPI
char default_auth_type[255];
/* DefaultAuthType value */
Expand All @@ -1611,7 +1600,6 @@ do_config_server(http_t *http) /* I - HTTP connection */
debug_logging = cgiGetVariable("DEBUG_LOGGING") ? "1" : "0";
remote_admin = cgiGetVariable("REMOTE_ADMIN") ? "1" : "0";
remote_any = cgiGetVariable("REMOTE_ANY") ? "1" : "0";
remote_printers = cgiGetVariable("REMOTE_PRINTERS") ? "1" : "0";
share_printers = cgiGetVariable("SHARE_PRINTERS") ? "1" : "0";
user_cancel_any = cgiGetVariable("USER_CANCEL_ANY") ? "1" : "0";

Expand All @@ -1637,66 +1625,6 @@ do_config_server(http_t *http) /* I - HTTP connection */

if (!max_log_size || atof(max_log_size) <= 0.0)
max_log_size = "1m";

if (cgiGetVariable("BROWSE_LOCAL_CUPS"))
strcpy(local_protocols, "cups");
else
local_protocols[0] = '\0';

#ifdef HAVE_DNSSD
if (cgiGetVariable("BROWSE_LOCAL_DNSSD"))
{
if (local_protocols[0])
strcat(local_protocols, " dnssd");
else
strcat(local_protocols, "dnssd");
}
#endif /* HAVE_DNSSD */

#ifdef HAVE_LDAP
if (cgiGetVariable("BROWSE_LOCAL_LDAP"))
{
if (local_protocols[0])
strcat(local_protocols, " ldap");
else
strcat(local_protocols, "ldap");
}
#endif /* HAVE_LDAP */

#ifdef HAVE_LIBSLP
if (cgiGetVariable("BROWSE_LOCAL_SLP"))
{
if (local_protocols[0])
strcat(local_protocols, " slp");
else
strcat(local_protocols, "slp");
}
#endif /* HAVE_SLP */

if (cgiGetVariable("BROWSE_REMOTE_CUPS"))
strcpy(remote_protocols, "cups");
else
remote_protocols[0] = '\0';

#ifdef HAVE_LDAP
if (cgiGetVariable("BROWSE_REMOTE_LDAP"))
{
if (remote_protocols[0])
strcat(remote_protocols, " ldap");
else
strcat(remote_protocols, "ldap");
}
#endif /* HAVE_LDAP */

#ifdef HAVE_LIBSLP
if (cgiGetVariable("BROWSE_REMOTE_SLP"))
{
if (remote_protocols[0])
strcat(remote_protocols, " slp");
else
strcat(remote_protocols, "slp");
}
#endif /* HAVE_SLP */
}

/*
Expand Down Expand Up @@ -1760,16 +1688,6 @@ do_config_server(http_t *http) /* I - HTTP connection */
settings)) == NULL)
current_max_log_size = "1m";

if ((current_local_protocols = cupsGetOption("BrowseLocalProtocols",
num_settings,
settings)) == NULL)
current_local_protocols = CUPS_DEFAULT_BROWSE_LOCAL_PROTOCOLS;

if ((current_remote_protocols = cupsGetOption("BrowseRemoteProtocols",
num_settings,
settings)) == NULL)
current_remote_protocols = CUPS_DEFAULT_BROWSE_REMOTE_PROTOCOLS;

/*
* See if the settings have changed...
*/
Expand All @@ -1780,8 +1698,6 @@ do_config_server(http_t *http) /* I - HTTP connection */
num_settings, settings)) ||
strcmp(remote_any, cupsGetOption(CUPS_SERVER_REMOTE_ANY,
num_settings, settings)) ||
strcmp(remote_printers, cupsGetOption(CUPS_SERVER_REMOTE_PRINTERS,
num_settings, settings)) ||
strcmp(share_printers, cupsGetOption(CUPS_SERVER_SHARE_PRINTERS,
num_settings, settings)) ||
#ifdef HAVE_GSSAPI
Expand All @@ -1793,9 +1709,7 @@ do_config_server(http_t *http) /* I - HTTP connection */
num_settings, settings));

if (advanced && !changed)
changed = _cups_strcasecmp(local_protocols, current_local_protocols) ||
_cups_strcasecmp(remote_protocols, current_remote_protocols) ||
_cups_strcasecmp(browse_web_if, current_browse_web_if) ||
changed = _cups_strcasecmp(browse_web_if, current_browse_web_if) ||
_cups_strcasecmp(preserve_job_history, current_preserve_job_history) ||
_cups_strcasecmp(preserve_job_files, current_preserve_job_files) ||
_cups_strcasecmp(max_clients, current_max_clients) ||
Expand All @@ -1817,8 +1731,6 @@ do_config_server(http_t *http) /* I - HTTP connection */
remote_admin, num_settings, &settings);
num_settings = cupsAddOption(CUPS_SERVER_REMOTE_ANY,
remote_any, num_settings, &settings);
num_settings = cupsAddOption(CUPS_SERVER_REMOTE_PRINTERS,
remote_printers, num_settings, &settings);
num_settings = cupsAddOption(CUPS_SERVER_SHARE_PRINTERS,
share_printers, num_settings, &settings);
num_settings = cupsAddOption(CUPS_SERVER_USER_CANCEL_ANY,
Expand All @@ -1834,12 +1746,6 @@ do_config_server(http_t *http) /* I - HTTP connection */
* Add advanced settings...
*/

if (_cups_strcasecmp(local_protocols, current_local_protocols))
num_settings = cupsAddOption("BrowseLocalProtocols", local_protocols,
num_settings, &settings);
if (_cups_strcasecmp(remote_protocols, current_remote_protocols))
num_settings = cupsAddOption("BrowseRemoteProtocols", remote_protocols,
num_settings, &settings);
if (_cups_strcasecmp(browse_web_if, current_browse_web_if))
num_settings = cupsAddOption("BrowseWebIF", browse_web_if,
num_settings, &settings);
Expand Down Expand Up @@ -1878,7 +1784,8 @@ do_config_server(http_t *http) /* I - HTTP connection */
else
{
if (advanced)
cgiSetVariable("refresh_page", "5;URL=/admin/?OP=redirect&URL=/admin/?ADVANCEDSETTINGS=YES");
cgiSetVariable("refresh_page", "5;URL=/admin/?OP=redirect&"
"URL=/admin/?ADVANCEDSETTINGS=YES");
else
cgiSetVariable("refresh_page", "5;URL=/admin/?OP=redirect");
cgiStartHTML(cgiText(_("Change Settings")));
Expand Down Expand Up @@ -2359,8 +2266,7 @@ do_export(http_t *http) /* I - HTTP connection */
"printer-type", 0);

ippAddInteger(request, IPP_TAG_OPERATION, IPP_TAG_ENUM,
"printer-type-mask", CUPS_PRINTER_CLASS | CUPS_PRINTER_REMOTE |
CUPS_PRINTER_IMPLICIT);
"printer-type-mask", CUPS_PRINTER_CLASS | CUPS_PRINTER_REMOTE);

ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_KEYWORD,
"requested-attributes", NULL, "printer-name");
Expand Down Expand Up @@ -2696,10 +2602,6 @@ do_menu(http_t *http) /* I - HTTP connection */
settings)) != NULL && atoi(val))
cgiSetVariable("REMOTE_ANY", "CHECKED");

if ((val = cupsGetOption(CUPS_SERVER_REMOTE_PRINTERS, num_settings,
settings)) != NULL && atoi(val))
cgiSetVariable("REMOTE_PRINTERS", "CHECKED");

if ((val = cupsGetOption(CUPS_SERVER_SHARE_PRINTERS, num_settings,
settings)) != NULL && atoi(val))
cgiSetVariable("SHARE_PRINTERS", "CHECKED");
Expand All @@ -2722,49 +2624,6 @@ do_menu(http_t *http) /* I - HTTP connection */
cgiSetVariable("HAVE_DNSSD", "1");
#endif /* HAVE_DNSSD */

#ifdef HAVE_LDAP
cgiSetVariable("HAVE_LDAP", "1");
#endif /* HAVE_LDAP */

#ifdef HAVE_LIBSLP
cgiSetVariable("HAVE_LIBSLP", "1");
#endif /* HAVE_LIBSLP */

if ((val = cupsGetOption("BrowseRemoteProtocols", num_settings,
settings)) == NULL)
if ((val = cupsGetOption("BrowseProtocols", num_settings,
settings)) == NULL)
val = CUPS_DEFAULT_BROWSE_REMOTE_PROTOCOLS;

if (strstr(val, "cups") || strstr(val, "CUPS"))
cgiSetVariable("BROWSE_REMOTE_CUPS", "CHECKED");

if (strstr(val, "ldap") || strstr(val, "LDAP"))
cgiSetVariable("BROWSE_REMOTE_LDAP", "CHECKED");

if (strstr(val, "slp") || strstr(val, "SLP"))
cgiSetVariable("BROWSE_REMOTE_SLP", "CHECKED");

if ((val = cupsGetOption("BrowseLocalProtocols", num_settings,
settings)) == NULL)
if ((val = cupsGetOption("BrowseProtocols", num_settings,
settings)) == NULL)
val = CUPS_DEFAULT_BROWSE_LOCAL_PROTOCOLS;

if (strstr(val, "cups") || strstr(val, "CUPS"))
cgiSetVariable("BROWSE_LOCAL_CUPS", "CHECKED");

if (strstr(val, "dnssd") || strstr(val, "DNSSD") ||
strstr(val, "dns-sd") || strstr(val, "DNS-SD") ||
strstr(val, "bonjour") || strstr(val, "BONJOUR"))
cgiSetVariable("BROWSE_LOCAL_DNSSD", "CHECKED");

if (strstr(val, "ldap") || strstr(val, "LDAP"))
cgiSetVariable("BROWSE_LOCAL_LDAP", "CHECKED");

if (strstr(val, "slp") || strstr(val, "SLP"))
cgiSetVariable("BROWSE_LOCAL_SLP", "CHECKED");

if ((val = cupsGetOption("BrowseWebIF", num_settings,
settings)) == NULL)
val = "No";
Expand Down
Loading

0 comments on commit a2326b5

Please sign in to comment.