CHANGES IN CUPS V2.1.4
- - Documentation update (STR #4772)
+ - The cups-lpd mini-daemon incorrectly included the document-name
+ attribute when creating a job. It should only be included when
+ sending a job (Issue #4790)
+ - Documentation update (Issue #4772)
CHANGES IN CUPS V2.1.3
- The default password function did not work on some platforms
- (STR #4750)
+ (Issue #4750)
- The scheduler should not exit under memory pressure
(<rdar://problem/23255001>)
- The EPL2 and ZPL sample drivers did not properly support the CutMedia
option.
- Pending subscriptions would prevent the scheduler from idle exiting
- (STR #4754)
+ (Issue #4754)
- Fixed some issues in ipptool for skipped tests
(<rdar://problem/24137160>)
- The "lp -H resume" command did not reset the "job-state-reasons"
- attribute value (STR #4752)
+ attribute value (Issue #4752)
- cupsEncodeOptions2 incorrectly handled escaped values
(<rdar://problem/19736672>)
- The scheduler did not allow access to resource files (icons, etc.)
- when the web interface was disabled (STR #4755)
- - Localization fix (STR #4756)
+ when the web interface was disabled (Issue #4755)
+ - Localization fix (Issue #4756)
CHANGES IN CUPS V2.1.2
<rdar://problem/23135122>, <rdar://problem/23135207>,
<rdar://problem/23144290>, <rdar://problem/23144358>,
<rdar://problem/23144461>)
- - The cupsGetPPD* functions did not work with IPP printers (STR #4725)
+ - The cupsGetPPD* functions did not work with IPP printers (Issue #4725)
- Some older HP LaserJet printers need a delayed close when printing
- using the libusb-based USB backend (STR #4549)
+ using the libusb-based USB backend (Issue #4549)
- The libusb-based USB backend did not unload the kernel usblp module
if it was preventing the backend from accessing the printer
- (STR #4707)
+ (Issue #4707)
- Current Primera printers were incorrectly reported as Fargo printers
- (STR #4708)
+ (Issue #4708)
- The IPP backend did not always handle jobs getting canceled at the
printer (<rdar://problem/22716820>)
- - Scheduler logging change (STR #4728)
- - Added USB quirk for Canon MP530 (STR #4730)
+ - Scheduler logging change (Issue #4728)
+ - Added USB quirk for Canon MP530 (Issue #4730)
- The scheduler did not deliver job notifications for jobs submitted to
- classes (STR #4733)
+ classes (Issue #4733)
- Changing the printer-is-shared value for a remote queue did not
- produce an error (STR #4738)
+ produce an error (Issue #4738)
- The IPP backend incorrectly included the job-password attribute in
Validate-Job requests (<rdar://problem/23531939>)
- - Updated localizations (STR #4709)
+ - Updated localizations (Issue #4709)
CHANGES IN CUPS V2.1.0
- - Fixed more scheduler crash bugs in the new logging code (STR #4687,
- STR #4690)
+ - Fixed more scheduler crash bugs in the new logging code (Issue #4687,
+ Issue #4690)
- The scheduler did not use the ConfigFilePerm setting when copying PPD
- files or interface scripts attached to a request (STR #4703)
+ files or interface scripts attached to a request (Issue #4703)
- Now support new Chinese locale IDs and their correct fallback locales
(<rdar://problem/22086642>, <rdar://problem/22130168>)
- "make check" incorrectly reported an expectation of 18 warning
- messages when 8 were expected (STR #4684)
- - The new PDF file type rule did not work (STR #4692)
+ messages when 8 were expected (Issue #4684)
+ - The new PDF file type rule did not work (Issue #4692)
- The scheduler did not update the jobs.cache file when job files were
- expired (STR #4706)
- - Fixed some configure script issues (STR #4694, STR #4695, STR #4698)
- - Documentation updates (STR #4691, STR #4693)
+ expired (Issue #4706)
+ - Fixed some configure script issues (Issue #4694, Issue #4695, Issue #4698)
+ - Documentation updates (Issue #4691, Issue #4693)
CHANGES IN CUPS V2.1rc1
- Added support for 3D printers (basic types only, no built-in filters)
based on PWG white paper.
- - Fixed bugs in the new journald support (STR #4655, STR #4658,
- STR #4661)
- - Fixed domain socket support on Linux (STR #4679)
- - Fixed signal handlers in the dnssd and usb backends (STR #4671)
+ - Fixed bugs in the new journald support (Issue #4655, Issue #4658,
+ Issue #4661)
+ - Fixed domain socket support on Linux (Issue #4679)
+ - Fixed signal handlers in the dnssd and usb backends (Issue #4671)
- <Limit All> in <Policy> sections now applies to all operations when
- used by itself (STR #4659)
- - Configure script changes for systemd support (STR #4669)
- - Updated autoconf sources to use newer form of AC_INIT (STR #4664)
+ used by itself (Issue #4659)
+ - Configure script changes for systemd support (Issue #4669)
+ - Updated autoconf sources to use newer form of AC_INIT (Issue #4664)
CHANGES IN CUPS V2.1b1
- The IPP backend now updates the cupsMandatory values when the printer
configuration changes (<rdar://problem/18126570>)
- No longer install banner files since third-party banner filters now
- supply their own (STR #4518)
+ supply their own (Issue #4518)
- Added support for EXPECT-ALL directive in ipptool test files
- (STR #4469)
+ (Issue #4469)
- Added support for WITH-VALUE-FROM predicate in ipptool test files
- (STR #4470)
+ (Issue #4470)
- The scheduler no longer listens on the loopback interface unless the
web interface or printer sharing are enabled
(<rdar://problem/9136448>)
- - Added a PPD generator for IPP Everywhere printers (STR #4258)
+ - Added a PPD generator for IPP Everywhere printers (Issue #4258)
- Now install "default" versions of more configuration files
(<rdar://problem/19024491>)
- The cupstestppd program did not handle "maxsize(nnn)" entries in
cupsFilter/cupsFilter2 values (<rdar://problem/18974858>)
- The scheduler now checks the return value of rename() calls
- (STR #4589)
+ (Issue #4589)
- The scheduler now validates ErrorPolicy values in config files
- (STR #4591)
- - Long cookies caused the web interface to stop working (STR #4619)
+ (Issue #4591)
+ - Long cookies caused the web interface to stop working (Issue #4619)
- Added SSLOptions values to allow Diffie-Hellman key exchange and
disable TLS/1.0 support.
- Updated the scheduler to support more IPP Everywhere attributes
- (STR #4630)
+ (Issue #4630)
- The scheduler now supports advanced ASL and journald logging when
- "syslog" output is configured (STR #4474)
+ "syslog" output is configured (Issue #4474)
- The scheduler now supports logging to stderr when running in the
- foreground (STR #4505)
+ foreground (Issue #4505)
/*
- * "$Id$"
- *
* Line Printer Daemon interface for CUPS.
*
- * Copyright 2007-2015 by Apple Inc.
+ * Copyright 2007-2016 by Apple Inc.
* Copyright 1997-2006 by Easy Software Products, all rights reserved.
*
* These coded instructions, statements, and computer programs are the
* Include necessary headers...
*/
+#define _CUPS_NO_DEPRECATED
#include <cups/cups-private.h>
#include <syslog.h>
#include <unistd.h>
* Setup the Create-Job request...
*/
- request = ippNewRequest(IPP_CREATE_JOB);
+ request = ippNewRequest(IPP_OP_CREATE_JOB);
httpAssembleURIf(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL,
"localhost", 0, "/printers/%s", dest);
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "job-name",
NULL, title);
- if (docname[0])
- ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "document-name",
- NULL, docname);
-
cupsEncodeOptions(request, num_options, options);
/*
response = cupsDoRequest(http, request, uri);
- if (!response || cupsLastError() > IPP_OK_CONFLICT)
+ if (!response || cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
syslog(LOG_ERR, "Unable to create job - %s", cupsLastErrorString());
if (shared)
*shared = 0;
if (state)
- *state = IPP_PRINTER_STOPPED;
+ *state = IPP_PSTATE_STOPPED;
if (options)
*options = NULL;
* Setup the Get-Printer-Attributes request...
*/
- request = ippNewRequest(IPP_GET_PRINTER_ATTRIBUTES);
+ request = ippNewRequest(IPP_OP_GET_PRINTER_ATTRIBUTES);
httpAssembleURIf(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL,
"localhost", 0, "/printers/%s", dest);
response = cupsDoRequest(http, request, "/");
- if (!response || cupsLastError() > IPP_OK_CONFLICT)
+ if (!response || cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
/*
* If we can't find the printer by name, look up the printer-name
* Setup the CUPS-Get-Printers request...
*/
- request = ippNewRequest(CUPS_GET_PRINTERS);
+ request = ippNewRequest(IPP_OP_CUPS_GET_PRINTERS);
ippAddStrings(request, IPP_TAG_OPERATION, IPP_TAG_KEYWORD,
"requested-attributes",
response = cupsDoRequest(http, request, "/");
- if (!response || cupsLastError() > IPP_OK_CONFLICT)
+ if (!response || cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
syslog(LOG_ERR, "Unable to get list of printers - %s",
cupsLastErrorString());
* Setup the Send-Document request...
*/
- request = ippNewRequest(IPP_SEND_DOCUMENT);
+ request = ippNewRequest(IPP_OP_SEND_DOCUMENT);
snprintf(uri, sizeof(uri), "ipp://localhost/jobs/%d", id);
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_URI, "job-uri", NULL, uri);
ippDelete(cupsDoFileRequest(http, request, uri, filename));
- if (cupsLastError() > IPP_OK_CONFLICT)
+ if (cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
syslog(LOG_ERR, "Unable to send document - %s", cupsLastErrorString());
* Connect to the server...
*/
- http = httpConnectEncrypt(cupsServer(), ippPort(), cupsEncryption());
+ http = httpConnect2(cupsServer(), ippPort(), NULL, AF_UNSPEC, cupsEncryption(), 1, 30000, NULL);
if (!http)
{
syslog(LOG_ERR, "Unable to connect to server: %s", strerror(errno));
* Try connecting to the local server...
*/
- if ((http = httpConnectEncrypt(cupsServer(), ippPort(),
- cupsEncryption())) == NULL)
+ if ((http = httpConnect2(cupsServer(), ippPort(), NULL, AF_UNSPEC, cupsEncryption(), 1, 30000, NULL)) == NULL)
{
syslog(LOG_ERR, "Unable to connect to server %s: %s", cupsServer(),
strerror(errno));
list ++;
/*
- * Build an IPP_CANCEL_JOB request, which requires the following
+ * Build an IPP_OP_CANCEL_JOB request, which requires the following
* attributes:
*
* attributes-charset
* requesting-user-name
*/
- request = ippNewRequest(IPP_CANCEL_JOB);
+ request = ippNewRequest(IPP_OP_CANCEL_JOB);
sprintf(uri, "ipp://localhost/jobs/%d", id);
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_URI, "job-uri", NULL, uri);
ippDelete(cupsDoRequest(http, request, "/jobs"));
- if (cupsLastError() > IPP_OK_CONFLICT)
+ if (cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
syslog(LOG_WARNING, "Cancel of job ID %d failed: %s\n", id,
cupsLastErrorString());
* Try connecting to the local server...
*/
- if ((http = httpConnectEncrypt(cupsServer(), ippPort(),
- cupsEncryption())) == NULL)
+ if ((http = httpConnect2(cupsServer(), ippPort(), NULL, AF_UNSPEC, cupsEncryption(), 1, 30000, NULL)) == NULL)
{
syslog(LOG_ERR, "Unable to connect to server %s: %s", cupsServer(),
strerror(errno));
switch (state)
{
- case IPP_PRINTER_IDLE :
+ case IPP_PSTATE_IDLE :
printf("%s is ready\n", dest);
break;
- case IPP_PRINTER_PROCESSING :
+ case IPP_PSTATE_PROCESSING :
printf("%s is ready and printing\n", dest);
break;
- case IPP_PRINTER_STOPPED :
+ case IPP_PSTATE_STOPPED :
printf("%s is not ready\n", dest);
break;
}
/*
- * Build an IPP_GET_JOBS or IPP_GET_JOB_ATTRIBUTES request, which requires
+ * Build an IPP_OP_GET_JOBS or IPP_OP_GET_JOB_ATTRIBUTES request, which requires
* the following attributes:
*
* attributes-charset
id = atoi(list);
- request = ippNewRequest(id ? IPP_GET_JOB_ATTRIBUTES : IPP_GET_JOBS);
+ request = ippNewRequest(id ? IPP_OP_GET_JOB_ATTRIBUTES : IPP_OP_GET_JOBS);
httpAssembleURIf(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL,
"localhost", 0, "/printers/%s", dest);
jobcount = 0;
response = cupsDoRequest(http, request, "/");
- if (cupsLastError() > IPP_OK_CONFLICT)
+ if (cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
printf("get-jobs failed: %s\n", cupsLastErrorString());
ippDelete(response);
jobid = 0;
jobsize = 0;
- jobstate = IPP_JOB_PENDING;
+ jobstate = IPP_JSTATE_PENDING;
jobname = "untitled";
jobuser = NULL;
jobdest = NULL;
* Display the job...
*/
- if (jobstate == IPP_JOB_PROCESSING)
+ if (jobstate == IPP_JSTATE_PROCESSING)
strlcpy(rankstr, "active", sizeof(rankstr));
else
{
else
return (s);
}
-
-
-/*
- * End of "$Id$".
- */