From: msweet Date: Sat, 29 Aug 2009 06:12:06 +0000 (+0000) Subject: Import changes from CUPS 1.4.1 (r8801) X-Git-Tag: release-1.6.3~89 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=7a0cbd5e5715d715c3fddfaace2f800ef820d328;p=thirdparty%2Fcups.git Import changes from CUPS 1.4.1 (r8801) git-svn-id: svn+ssh://src.apple.com/svn/cups/easysw/current@1649 a1ca3aef-8c08-0410-bb20-df032aa958be --- diff --git a/CHANGES.txt b/CHANGES.txt index ea17aa96c0..e101a5c247 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -1,6 +1,39 @@ -CHANGES.txt - 2009-08-07 +CHANGES.txt - 2009-08-28 ------------------------ +CHANGES IN CUPS V1.4.1 + + - Documention fixes (STR #3296) + - DNS-SD registrations for raw queues had an empty "ty" key (STR #3299) + - The JPEG and BMP MIME type rules were broken (STR #3284) + - cupsGetNamedDest returned the default printer when the named + destination did not exist (STR #3285) + - The JobKillDelay was not triggered for canceled jobs (STR #3292) + - The PPD compiler could get in an infinite loop (STR #3293) + - The configure check for dns-sd.h was broken (STR #3297) + - The "Query Printer for Default Options" page did not go away if the + query job was held (STR #3302) + - Boolean options did not show up as selected in the web interface + (STR #3303) + - The scheduler did not cache or report driver information files + correctly, leading to a variety of issues (STR #3283, STR #3297, + STR #3305) + - cupsDoIORequest() did not abort on permanent errors (STR #3311) + - Modifying a class in the web interface did not work (STR #3312) + - BrowseLocalProtocols could be cleared when changing the sharing + setting (STR #3287) + - The scheduler could return an empty supported document format + (STR #3308) + - The PPD compiler generated invalid PPD files when the locale used + something other than "." for the decimal point (STR #3300) + - The IPP backend did not handle some non-comforming IPP printer + implementations (STR #3262) + - The scheduler leaked three file descriptors to each job filter + (STR #3263) + - The scheduler now uses a default CUPS-Get-Devices timeout of 15 + seconds (STR #3307) + + CHANGES IN CUPS V1.4.0 - Localization updates (STR #3223, STR #3246, STR #3248, STR #3250) diff --git a/backend/ipp.c b/backend/ipp.c index 4301b2eab7..65c254c860 100644 --- a/backend/ipp.c +++ b/backend/ipp.c @@ -1239,6 +1239,19 @@ main(int argc, /* I - Number of command-line args */ break; } } + else + { + /* + * If the printer does not return a job-state attribute, it does not + * conform to the IPP specification - break out immediately and fail + * the job... + */ + + fputs("DEBUG: No job-state available from printer - stopping queue.\n", + stderr); + ipp_status = IPP_INTERNAL_ERROR; + break; + } } ippDelete(response); @@ -1317,6 +1330,8 @@ main(int argc, /* I - Number of command-line args */ if (ipp_status == IPP_NOT_AUTHORIZED) return (CUPS_BACKEND_AUTH_REQUIRED); + else if (ipp_status == IPP_INTERNAL_ERROR) + return (CUPS_BACKEND_STOP); else if (ipp_status > IPP_OK_CONFLICT) return (CUPS_BACKEND_FAILED); else diff --git a/cgi-bin/admin.c b/cgi-bin/admin.c index ddddd76edf..8271dfc089 100644 --- a/cgi-bin/admin.c +++ b/cgi-bin/admin.c @@ -634,6 +634,15 @@ do_am_class(http_t *http, /* I - HTTP connection */ return; } + if (!name) + { + cgiStartHTML(title); + cgiSetVariable("ERROR", cgiText(_("Missing form variable!"))); + cgiCopyTemplateLang("error.tmpl"); + cgiEndHTML(); + return; + } + for (ptr = name; *ptr; ptr ++) if ((*ptr >= 0 && *ptr <= ' ') || *ptr == 127 || *ptr == '/' || *ptr == '#') break; @@ -668,8 +677,7 @@ do_am_class(http_t *http, /* I - HTTP connection */ request = ippNewRequest(CUPS_ADD_CLASS); httpAssembleURIf(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL, - "localhost", 0, "/classes/%s", - cgiGetVariable("PRINTER_NAME")); + "localhost", 0, "/classes/%s", name); ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri", NULL, uri); diff --git a/cgi-bin/ipp-var.c b/cgi-bin/ipp-var.c index 1b63056fa0..096fd22944 100644 --- a/cgi-bin/ipp-var.c +++ b/cgi-bin/ipp-var.c @@ -650,7 +650,8 @@ cgiPrintCommand(http_t *http, /* I - Connection to server */ cgiSetIPPVars(response, NULL, NULL, NULL, 0); attr = ippFindAttribute(response, "job-state", IPP_TAG_ENUM); - if (!attr || attr->values[0].integer >= IPP_JOB_STOPPED) + if (!attr || attr->values[0].integer >= IPP_JOB_STOPPED || + attr->values[0].integer == IPP_JOB_HELD) { ippDelete(response); break; diff --git a/conf/mime.types b/conf/mime.types index ba97930d54..8ef1c06a9e 100644 --- a/conf/mime.types +++ b/conf/mime.types @@ -95,7 +95,7 @@ application/vnd.hp-HPGL hpgl \ image/gif gif string(0,GIF87a) string(0,GIF89a) image/png png string(0,<89>PNG) -image/jpeg jpeg jpg jpe string(0,) &&\ +image/jpeg jpeg jpg jpe string(0,) +\ (char(3,0xe0) char(3,0xe1) char(3,0xe2) char(3,0xe3)\ char(3,0xe4) char(3,0xe5) char(3,0xe6) char(3,0xe7)\ char(3,0xe8) char(3,0xe9) char(3,0xea) char(3,0xeb)\ @@ -114,7 +114,7 @@ image/x-sun-raster ras string(0,<59a66a95>) #image/fpx fpx image/x-alias pix short(8,8) short(8,24) -image/x-bitmap bmp string(0,BM) && !printable(2,14) +image/x-bitmap bmp string(0,BM) + !printable(2,14) image/x-icon ico ######################################################################## diff --git a/config-scripts/cups-common.m4 b/config-scripts/cups-common.m4 index 11bffc60c9..d0535dd3b7 100644 --- a/config-scripts/cups-common.m4 +++ b/config-scripts/cups-common.m4 @@ -20,7 +20,7 @@ dnl Set the name of the config header file... AC_CONFIG_HEADER(config.h) dnl Version number information... -CUPS_VERSION="1.4.0" +CUPS_VERSION="1.4.1" CUPS_REVISION="" #if test -z "$CUPS_REVISION" -a -d .svn; then # CUPS_REVISION="-r`svnversion . | awk -F: '{print $NF}' | sed -e '1,$s/[[a-zA-Z]]*//g'`" diff --git a/config-scripts/cups-dnssd.m4 b/config-scripts/cups-dnssd.m4 index fcc4e00408..cd209cdbd0 100644 --- a/config-scripts/cups-dnssd.m4 +++ b/config-scripts/cups-dnssd.m4 @@ -43,7 +43,7 @@ if test x$enable_dnssd != xno; then AC_MSG_CHECKING(for current version of dns_sd library) SAVELIBS="$LIBS" LIBS="$LIBS -ldns_sd" - AC_TRY_COMPILE([#include ], [int constant = kDNSServiceFlagsShareConnection; unsigned char txtRecord[100]; uint8_t valueLen; diff --git a/cups/adminutil.c b/cups/adminutil.c index 826ec86bd7..54e72f5822 100644 --- a/cups/adminutil.c +++ b/cups/adminutil.c @@ -1553,7 +1553,7 @@ _cupsAdminSetServerSettings( const char *remotep = cupsGetOption("BrowseRemoteProtocols", num_settings, settings); - if (!localp) + if (!localp || !localp[0]) localp = cupsGetOption("BrowseLocalProtocols", cupsd_num_settings, cupsd_settings); diff --git a/cups/cups.h b/cups/cups.h index c3b7f2f8af..09aa2d1c43 100644 --- a/cups/cups.h +++ b/cups/cups.h @@ -59,10 +59,10 @@ extern "C" { * Constants... */ -# define CUPS_VERSION 1.0400 +# define CUPS_VERSION 1.0401 # define CUPS_VERSION_MAJOR 1 # define CUPS_VERSION_MINOR 4 -# define CUPS_VERSION_PATCH 0 +# define CUPS_VERSION_PATCH 1 # define CUPS_BC_FD 3 /* Back-channel file descriptor for select/poll */ # define CUPS_DATE_ANY (time_t)-1 diff --git a/cups/dest.c b/cups/dest.c index 4aedcb216b..54a393421b 100644 --- a/cups/dest.c +++ b/cups/dest.c @@ -557,7 +557,7 @@ cupsGetNamedDest(http_t *http, /* I - Connection to server or @code CUPS_HTT * configuration file does not exist. Find out the real default. */ - if (!cups_get_sdests(http, CUPS_GET_DEFAULT, name, 0, &dest)) + if (!cups_get_sdests(http, CUPS_GET_DEFAULT, NULL, 0, &dest)) return (NULL); } @@ -1800,7 +1800,7 @@ cups_get_sdests(http_t *http, /* I - Connection to server or CUPS_HTTP_DEFA ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "requesting-user-name", NULL, cupsUser()); - if (name) + if (name && op != CUPS_GET_DEFAULT) { httpAssembleURIf(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL, "localhost", ippPort(), "/printers/%s", name); diff --git a/vc2005/libcups2.def b/cups/libcups2.def similarity index 97% rename from vc2005/libcups2.def rename to cups/libcups2.def index 376fc2d4ba..1f99d8888e 100644 --- a/vc2005/libcups2.def +++ b/cups/libcups2.def @@ -29,10 +29,14 @@ _cupsStrStatistics _cups_strcpy _cups_strlcat _cups_strlcpy +_httpResolveURI _ippAddAttr _ippFindOption _ippFreeAttr +_ppdFreeLanguages _ppdGetEncoding +_ppdGetLanguages +_ppdHashName cupsAddDest cupsAddOption cupsAdminCreateWindowsPPD @@ -129,6 +133,7 @@ cupsPrintFiles2 cupsPutFd cupsPutFile cupsRemoveOption +cupsResolveConflicts cupsServer cupsSetDests cupsSetDests2 diff --git a/cups/request.c b/cups/request.c index 6eacf79250..722dcdf0f8 100644 --- a/cups/request.c +++ b/cups/request.c @@ -266,7 +266,9 @@ cupsDoIORequest(http_t *http, /* I - Connection to server or @code CUPS_HTTP DEBUG_printf(("2cupsDoIORequest: status=%d", status)); - if (status == HTTP_FORBIDDEN || status >= HTTP_SERVER_ERROR) + if (status >= HTTP_BAD_REQUEST && + status != HTTP_UNAUTHORIZED && + status != HTTP_UPGRADE_REQUIRED) { httpFlush(http); _cupsSetHTTPError(status); diff --git a/cups/testfile.c b/cups/testfile.c index 43751f116e..e25bf95028 100644 --- a/cups/testfile.c +++ b/cups/testfile.c @@ -64,8 +64,10 @@ main(int argc, /* I - Number of command-line arguments */ int status; /* Exit status */ char filename[1024]; /* Filename buffer */ cups_file_t *fp; /* File pointer */ +#ifndef WIN32 int fds[2]; /* Open file descriptors */ cups_file_t *fdfile; /* File opened with cupsFileOpenFd() */ +#endif /* !WIN32 */ int count; /* Number of lines in file */ @@ -93,6 +95,7 @@ main(int argc, /* I - Number of command-line arguments */ status += random_tests(); +#ifndef WIN32 /* * Test fdopen and close without reading... */ @@ -126,6 +129,7 @@ main(int argc, /* I - Number of command-line arguments */ puts("PASS"); } +#endif /* !WIN32 */ /* * Count lines in euc-jp.txt, rewind, then count again. @@ -756,7 +760,7 @@ read_write_tests(int compression) /* I - Use compression? */ fputs("cupsFileGetChar(partial line): ", stdout); - for (i = 0; i < strlen(partial_line); i ++) + for (i = 0; i < (int)strlen(partial_line); i ++) if ((byte = cupsFileGetChar(fp)) < 0) break; else if (byte != partial_line[i]) diff --git a/cups/testhttp.c b/cups/testhttp.c index 3e10a76342..41d9ce6f1d 100644 --- a/cups/testhttp.c +++ b/cups/testhttp.c @@ -247,7 +247,7 @@ main(int argc, /* I - Number of command-line arguments */ for (i = 0, j = 0; i < (int)(sizeof(base64_tests) / sizeof(base64_tests[0])); i ++) { httpEncode64_2(encode, sizeof(encode), base64_tests[i][0], - strlen(base64_tests[i][0])); + (int)strlen(base64_tests[i][0])); decodelen = (int)sizeof(decode); httpDecode64_2(decode, &decodelen, base64_tests[i][1]); diff --git a/doc/help/spec-ipp.html b/doc/help/spec-ipp.html index 1be65c0bd2..ae043e744d 100644 --- a/doc/help/spec-ipp.html +++ b/doc/help/spec-ipp.html @@ -1603,8 +1603,8 @@ CUPS-Get-Devices request:
"timeout" (integer (1:MAX)) :CUPS 1.4/Mac OS X 10.6 -
The client OPTIONALLY supplies this attribute limiting the number of - devices that are returned. +
The client OPTIONALLY supplies this attribute to limit the duration + of the lookup. The default timeout is 15 seconds. diff --git a/filter/image-private.h b/filter/image-private.h index 79d440a80e..0950cba0b6 100644 --- a/filter/image-private.h +++ b/filter/image-private.h @@ -29,7 +29,11 @@ # include # include # include -# include +# ifdef WIN32 +# include +# else +# include +# endif /* WIN32 */ # include # include diff --git a/man/lprm.man b/man/lprm.man index e8da74e6d4..faf48d18e2 100644 --- a/man/lprm.man +++ b/man/lprm.man @@ -12,7 +12,7 @@ .\" which should have been included with this file. If this file is .\" file is missing or damaged, see the license at "http://www.cups.org/". .\" -.TH lprm 1 "CUPS" "12 February 2006" "Apple Inc." +.TH lprm 1 "CUPS" "28 August 2009" "Apple Inc." .SH NAME lprm \- cancel print jobs .SH SYNOPSIS @@ -49,7 +49,7 @@ Specifies an alternate username. .TP 5 -h server[:port] .br -Specifies and alternate server. +Specifies an alternate server. .SH COMPATIBILITY The CUPS version of \fIlprm\fR is compatible with the standard Berkeley \fIlprm\fR command. diff --git a/ppdc/ppdc-driver.cxx b/ppdc/ppdc-driver.cxx index 6ad44207e0..a159329edd 100644 --- a/ppdc/ppdc-driver.cxx +++ b/ppdc/ppdc-driver.cxx @@ -554,6 +554,8 @@ ppdcDriver::write_ppd_file( else if (type != PPDC_DRIVER_PS) cupsFilePrintf(fp, "*TTRasterizer: Type42%s", lf); + struct lconv *loc = localeconv(); + if (attrs->count) { // Write driver-defined attributes... @@ -679,16 +681,23 @@ ppdcDriver::write_ppd_file( for (p = (ppdcProfile *)profiles->first(); p; p = (ppdcProfile *)profiles->next()) + { + char density[255], gamma[255], profile[9][255]; + + _cupsStrFormatd(density, density + sizeof(density), p->density, loc); + _cupsStrFormatd(gamma, gamma + sizeof(gamma), p->gamma, loc); + + for (int i = 0; i < 9; i ++) + _cupsStrFormatd(profile[i], profile[i] + sizeof(profile[0]), + p->profile[i], loc); + cupsFilePrintf(fp, - "*cupsColorProfile %s/%s: \"%.3f %.3f %.3f %.3f %.3f %.3f " - "%.3f %.3f %.3f %.3f %.3f\"%s", - p->resolution->value, p->media_type->value, - p->density, p->gamma, - p->profile[0], p->profile[1], - p->profile[2], p->profile[3], - p->profile[4], p->profile[5], - p->profile[6], p->profile[7], - p->profile[8], lf); + "*cupsColorProfile %s/%s: \"%s %s %s %s %s %s %s %s %s %s " + "%s\"%s", p->resolution->value, p->media_type->value, + density, gamma, profile[0], profile[1], profile[2], + profile[3], profile[4], profile[5], profile[6], profile[7], + profile[8], lf); + } } if (locales) @@ -871,13 +880,21 @@ ppdcDriver::write_ppd_file( cupsFilePrintf(fp, "*DefaultImageableArea: %s%s", default_size ? default_size->value : "Letter", lf); + char left[255], right[255], bottom[255], top[255]; + for (m = (ppdcMediaSize *)sizes->first(); m; m = (ppdcMediaSize *)sizes->next()) - cupsFilePrintf(fp, "*ImageableArea %s/%s: \"%.2f %.2f %.2f %.2f\"%s", + { + _cupsStrFormatd(left, left + sizeof(left), m->left, loc); + _cupsStrFormatd(bottom, bottom + sizeof(bottom), m->bottom, loc); + _cupsStrFormatd(right, right + sizeof(right), m->width - m->right, loc); + _cupsStrFormatd(top, top + sizeof(top), m->length - m->top, loc); + + cupsFilePrintf(fp, "*ImageableArea %s/%s: \"%s %s %s %s\"%s", m->name->value, catalog->find_message(m->text->value), - m->left, m->bottom, m->width - m->right, m->length - m->top, - lf); + left, bottom, right, top, lf); + } if ((a = find_attr("?ImageableArea", NULL)) != NULL) { @@ -892,12 +909,19 @@ ppdcDriver::write_ppd_file( cupsFilePrintf(fp, "*DefaultPaperDimension: %s%s", default_size ? default_size->value : "Letter", lf); + char width[255], length[255]; + for (m = (ppdcMediaSize *)sizes->first(); m; m = (ppdcMediaSize *)sizes->next()) - cupsFilePrintf(fp, "*PaperDimension %s/%s: \"%.2f %.2f\"%s", + { + _cupsStrFormatd(width, width + sizeof(width), m->width, loc); + _cupsStrFormatd(length, length + sizeof(length), m->length, loc); + + cupsFilePrintf(fp, "*PaperDimension %s/%s: \"%s %s\"%s", m->name->value, catalog->find_message(m->text->value), - m->width, m->length, lf); + width, length, lf); + } if ((a = find_attr("?PaperDimension", NULL)) != NULL) { @@ -911,10 +935,18 @@ ppdcDriver::write_ppd_file( // Custom size support... if (variable_paper_size) { - cupsFilePrintf(fp, "*MaxMediaWidth: \"%.2f\"%s", max_width, lf); - cupsFilePrintf(fp, "*MaxMediaHeight: \"%.2f\"%s", max_length, lf); - cupsFilePrintf(fp, "*HWMargins: %.2f %.2f %.2f %.2f\n", - left_margin, bottom_margin, right_margin, top_margin); + _cupsStrFormatd(width, width + sizeof(width), max_width, loc); + _cupsStrFormatd(length, length + sizeof(length), max_length, loc); + + _cupsStrFormatd(left, left + sizeof(left), left_margin, loc); + _cupsStrFormatd(bottom, bottom + sizeof(bottom), bottom_margin, loc); + _cupsStrFormatd(right, right + sizeof(right), right_margin, loc); + _cupsStrFormatd(top, top + sizeof(top), top_margin, loc); + + cupsFilePrintf(fp, "*MaxMediaWidth: \"%s\"%s", width, lf); + cupsFilePrintf(fp, "*MaxMediaHeight: \"%s\"%s", length, lf); + cupsFilePrintf(fp, "*HWMargins: %s %s %s %s%s", left, bottom, right, top, + lf); if (custom_size_code && custom_size_code->value) { @@ -934,15 +966,29 @@ ppdcDriver::write_ppd_file( cupsFilePrintf(fp, "*ParamCustomPageSize Width: %s%s", a->value->value, lf); else - cupsFilePrintf(fp, "*ParamCustomPageSize Width: 1 points %.2f %.2f%s", - min_width, max_width, lf); + { + char width0[255]; + + _cupsStrFormatd(width0, width0 + sizeof(width0), min_width, loc); + _cupsStrFormatd(width, width + sizeof(width), max_width, loc); + + cupsFilePrintf(fp, "*ParamCustomPageSize Width: 1 points %s %s%s", + width0, width, lf); + } if ((a = find_attr("ParamCustomPageSize", "Height")) != NULL) cupsFilePrintf(fp, "*ParamCustomPageSize Height: %s%s", a->value->value, lf); else - cupsFilePrintf(fp, "*ParamCustomPageSize Height: 2 points %.2f %.2f%s", - min_length, max_length, lf); + { + char length0[255]; + + _cupsStrFormatd(length0, length0 + sizeof(length0), min_length, loc); + _cupsStrFormatd(length, length + sizeof(length), max_length, loc); + + cupsFilePrintf(fp, "*ParamCustomPageSize Height: 2 points %s %s%s", + length0, length, lf); + } if ((a = find_attr("ParamCustomPageSize", "WidthOffset")) != NULL) cupsFilePrintf(fp, "*ParamCustomPageSize WidthOffset: %s%s", @@ -1000,7 +1046,10 @@ ppdcDriver::write_ppd_file( break; } - cupsFilePrintf(fp, "*OrderDependency: %.1f ", o->order); + char order[255]; + _cupsStrFormatd(order, order + sizeof(order), o->order, loc); + + cupsFilePrintf(fp, "*OrderDependency: %s ", order); switch (o->section) { default : diff --git a/ppdc/ppdc-source.cxx b/ppdc/ppdc-source.cxx index 5898997fc8..0a044fe4ca 100644 --- a/ppdc/ppdc-source.cxx +++ b/ppdc/ppdc-source.cxx @@ -1321,7 +1321,7 @@ ppdcSource::get_integer(const char *v) // I - Value string while (*v && *v != ')') { // Skip leading whitespace... - while (*v && isspace(*v & 255)); + while (*v && isspace(*v & 255)) v ++; if (!*v || *v == ')') diff --git a/scheduler/cups-driverd.cxx b/scheduler/cups-driverd.cxx index a014f1ae92..1439dd7958 100644 --- a/scheduler/cups-driverd.cxx +++ b/scheduler/cups-driverd.cxx @@ -1493,13 +1493,21 @@ load_ppds(const char *d, /* I - Actual directory */ ppd->record.size == dent->fileinfo.st_size && ppd->record.mtime == dent->fileinfo.st_mtime) { - do - { - ppd->found = 1; - } - while ((ppd = (ppd_info_t *)cupsArrayNext(PPDsByName)) != NULL && + /* + * Rewind to the first entry for this file... + */ + + while ((ppd = (ppd_info_t *)cupsArrayPrev(PPDsByName)) != NULL && !strcmp(ppd->record.filename, name)); + /* + * Then mark all of the matches for this file as found... + */ + + while ((ppd = (ppd_info_t *)cupsArrayNext(PPDsByName)) != NULL && + !strcmp(ppd->record.filename, name)) + ppd->found = 1; + continue; } @@ -1904,7 +1912,8 @@ load_drv(const char *filename, /* I - Actual filename */ *cups_fax, // cupsFax attribute *nick_name; // NickName attribute ppdcFilter *filter; // Current filter - bool product_found; // Found product? + ppd_info_t *ppd; // Current PPD + int products_found; // Number of products found char uri[1024], // Driver URI make_model[1024]; // Make and model int type; // Driver type @@ -1929,7 +1938,7 @@ load_drv(const char *filename, /* I - Actual filename */ * Add a dummy entry for the file... */ - add_ppd(filename, filename, "", "", "", "", "", "", mtime, size, 0, + add_ppd(name, name, "", "", "", "", "", "", mtime, size, 0, PPD_TYPE_DRV, "drv"); ChangedPPD = 1; @@ -1981,22 +1990,28 @@ load_drv(const char *filename, /* I - Actual filename */ type = PPD_TYPE_PDF; } - for (product = (ppdcAttr *)d->attrs->first(), product_found = false; + for (product = (ppdcAttr *)d->attrs->first(), products_found = 0; product; product = (ppdcAttr *)d->attrs->next()) if (!strcmp(product->name->value, "Product")) { - product_found = true; + if (!products_found) + ppd = add_ppd(name, uri, "en", d->manufacturer->value, make_model, + device_id ? device_id->value->value : "", + product->value->value, + ps_version ? ps_version->value->value : "(3010) 0", + mtime, size, d->model_number, type, "drv"); + else if (products_found < PPD_MAX_PROD) + strlcpy(ppd->record.products[products_found], product->value->value, + sizeof(ppd->record.products[0])); + else + break; - add_ppd(filename, uri, "en", d->manufacturer->value, make_model, - device_id ? device_id->value->value : "", - product->value->value, - ps_version ? ps_version->value->value : "(3010) 0", - mtime, size, d->model_number, type, "drv"); + products_found ++; } - if (!product_found) - add_ppd(filename, uri, "en", d->manufacturer->value, make_model, + if (!products_found) + add_ppd(name, uri, "en", d->manufacturer->value, make_model, device_id ? device_id->value->value : "", d->model_name->value, ps_version ? ps_version->value->value : "(3010) 0", diff --git a/scheduler/dirsvc.c b/scheduler/dirsvc.c index 89bcaefbf1..49b2672737 100644 --- a/scheduler/dirsvc.c +++ b/scheduler/dirsvc.c @@ -1558,8 +1558,11 @@ cupsdStartBrowsing(void) * Add the master connection to the select list... */ - cupsdAddSelect(DNSServiceRefSockFD(DNSSDRef), - (cupsd_selfunc_t)dnssdUpdate, NULL, NULL); + int fd = DNSServiceRefSockFD(DNSSDRef); + + fcntl(fd, F_SETFD, fcntl(fd, F_GETFD) | FD_CLOEXEC); + + cupsdAddSelect(fd, (cupsd_selfunc_t)dnssdUpdate, NULL, NULL); /* * Then get the port we use for registrations. If we are not listening @@ -2369,7 +2372,7 @@ dnssdBuildTxtRecord( (p->type & CUPS_PRINTER_CLASS) ? "classes" : "printers", p->name); keyvalue[i ][0] = "ty"; - keyvalue[i++][1] = p->make_model; + keyvalue[i++][1] = p->make_model ? p->make_model : "Unknown"; if (p->location && *p->location != '\0') { diff --git a/scheduler/ipp.c b/scheduler/ipp.c index caa620b6b2..d212b20551 100644 --- a/scheduler/ipp.c +++ b/scheduler/ipp.c @@ -6556,7 +6556,7 @@ get_devices(cupsd_client_t *con) /* I - Client connection */ "%d+%d+%d+%d+%s%s%s%s%s", con->request->request.op.request_id, limit ? limit->values[0].integer : 0, - timeout ? timeout->values[0].integer : 10, + timeout ? timeout->values[0].integer : 15, (int)User, requested_str, exclude_str[0] ? "%20" : "", exclude_str, diff --git a/scheduler/job.c b/scheduler/job.c index 43060149f9..669e70f073 100644 --- a/scheduler/job.c +++ b/scheduler/job.c @@ -2297,17 +2297,32 @@ cupsdSetJobState( case IPP_JOB_ABORTED : case IPP_JOB_CANCELED : case IPP_JOB_COMPLETED : - /* - * Expire job subscriptions since the job is now "completed"... - */ + if (newstate == IPP_JOB_CANCELED) + { + /* + * Remove the job from the active list if there are no processes still + * running for it... + */ - cupsdExpireSubscriptions(NULL, job); + for (i = 0; job->filters[i] < 0; i++); + + if (!job->filters[i] && job->backend <= 0) + cupsArrayRemove(ActiveJobs, job); + } + else + { + /* + * Otherwise just remove the job from the active list immediately... + */ + + cupsArrayRemove(ActiveJobs, job); + } /* - * Remove the job from the active list... + * Expire job subscriptions since the job is now "completed"... */ - cupsArrayRemove(ActiveJobs, job); + cupsdExpireSubscriptions(NULL, job); #ifdef __APPLE__ /* @@ -3848,6 +3863,11 @@ start_job(cupsd_job_t *job, /* I - Job ID */ fcntl(job->side_pipes[1], F_SETFL, fcntl(job->side_pipes[1], F_GETFL) | O_NONBLOCK); + fcntl(job->side_pipes[0], F_SETFD, + fcntl(job->side_pipes[0], F_GETFD) | FD_CLOEXEC); + fcntl(job->side_pipes[1], F_SETFD, + fcntl(job->side_pipes[1], F_GETFD) | FD_CLOEXEC); + /* * Now start the first file in the job... */ diff --git a/scheduler/main.c b/scheduler/main.c index 39e7740277..75104557f7 100644 --- a/scheduler/main.c +++ b/scheduler/main.c @@ -1793,6 +1793,18 @@ process_children(void) cupsdContinueJob(job); } } + else if (job->state_value == IPP_JOB_CANCELED) + { + /* + * Remove the job from the active list if there are no processes still + * running for it... + */ + + for (i = 0; job->filters[i] < 0; i++); + + if (!job->filters[i] && job->backend <= 0) + cupsArrayRemove(ActiveJobs, job); + } } } diff --git a/scheduler/printers.c b/scheduler/printers.c index 6bc2616639..29f55231be 100644 --- a/scheduler/printers.c +++ b/scheduler/printers.c @@ -3699,10 +3699,6 @@ add_printer_formats(cupsd_printer_t *p) /* I - Printer */ p->name, mimetype); } - cupsdLogMessage(CUPSD_LOG_DEBUG2, - "add_printer_formats: %s: %d supported types", - p->name, cupsArrayCount(p->filetypes) + 1); - /* * Add the file formats that can be filtered... */ @@ -3713,9 +3709,13 @@ add_printer_formats(cupsd_printer_t *p) /* I - Printer */ else i = 0; + cupsdLogMessage(CUPSD_LOG_DEBUG2, + "add_printer_formats: %s: %d supported types", + p->name, cupsArrayCount(p->filetypes) + i); + attr = ippAddStrings(p->attrs, IPP_TAG_PRINTER, IPP_TAG_MIMETYPE, "document-format-supported", - cupsArrayCount(p->filetypes) + 1, NULL, NULL); + cupsArrayCount(p->filetypes) + i, NULL, NULL); if (i) attr->values[0].string.text = _cupsStrAlloc("application/octet-stream"); diff --git a/systemv/cupstestppd.c b/systemv/cupstestppd.c index f3c8bb66db..dda0f0e75e 100644 --- a/systemv/cupstestppd.c +++ b/systemv/cupstestppd.c @@ -50,6 +50,9 @@ #include #include #include +#ifdef WIN32 +# define X_OK 0 +#endif /* WIN32 */ /* @@ -1541,7 +1544,7 @@ main(int argc, /* I - Number of command-line args */ for (j = 0, group = ppd->groups; j < ppd->num_groups; j ++, group ++) for (k = 0, option = group->options; k < group->num_options; k ++, option ++) { - len = strlen(option->keyword); + len = (int)strlen(option->keyword); for (m = 0, group2 = ppd->groups; m < ppd->num_groups; @@ -1550,7 +1553,7 @@ main(int argc, /* I - Number of command-line args */ n < group2->num_options; n ++, option2 ++) if (option != option2 && - len < strlen(option2->keyword) && + len < (int)strlen(option2->keyword) && !strncmp(option->keyword, option2->keyword, len)) { _cupsLangPrintf(stdout, @@ -3070,7 +3073,7 @@ check_translations(ppd_file_t *ppd, /* I - PPD file */ language; language = (char *)cupsArrayNext(languages)) { - langlen = strlen(language); + langlen = (int)strlen(language); if (langlen != 2 && langlen != 5) { if (!warn && !errors && !verbose) diff --git a/templates/de/modify-class.tmpl b/templates/de/modify-class.tmpl index 853d929c88..1db4a3fd59 100644 --- a/templates/de/modify-class.tmpl +++ b/templates/de/modify-class.tmpl @@ -4,6 +4,7 @@
+ diff --git a/templates/de/option-boolean.tmpl b/templates/de/option-boolean.tmpl index 1b352bb1ff..e832ee1022 100644 --- a/templates/de/option-boolean.tmpl +++ b/templates/de/option-boolean.tmpl @@ -1,6 +1,6 @@ diff --git a/templates/es/modify-class.tmpl b/templates/es/modify-class.tmpl index 02eb7aa5d9..0dfb4736e8 100644 --- a/templates/es/modify-class.tmpl +++ b/templates/es/modify-class.tmpl @@ -4,6 +4,7 @@ +
{keytext}: -{[choices]{text}} +{[choices]{text}}
diff --git a/templates/es/option-boolean.tmpl b/templates/es/option-boolean.tmpl index 1b352bb1ff..e832ee1022 100644 --- a/templates/es/option-boolean.tmpl +++ b/templates/es/option-boolean.tmpl @@ -1,6 +1,6 @@ diff --git a/templates/eu/modify-class.tmpl b/templates/eu/modify-class.tmpl index 708fc7b269..dfd1322eaa 100644 --- a/templates/eu/modify-class.tmpl +++ b/templates/eu/modify-class.tmpl @@ -4,6 +4,7 @@ +
{keytext}: -{[choices]{text}} +{[choices]{text}}
diff --git a/templates/eu/option-boolean.tmpl b/templates/eu/option-boolean.tmpl index 2d0dd551a1..e832ee1022 100644 --- a/templates/eu/option-boolean.tmpl +++ b/templates/eu/option-boolean.tmpl @@ -1,6 +1,6 @@ diff --git a/templates/ja/modify-class.tmpl b/templates/ja/modify-class.tmpl index bb0c3294c4..c5fe07d5e0 100644 --- a/templates/ja/modify-class.tmpl +++ b/templates/ja/modify-class.tmpl @@ -4,6 +4,7 @@ +
{keytext}: -{[choices]{text}} +{[choices]{text}}
diff --git a/templates/ja/option-boolean.tmpl b/templates/ja/option-boolean.tmpl index 1b352bb1ff..e832ee1022 100644 --- a/templates/ja/option-boolean.tmpl +++ b/templates/ja/option-boolean.tmpl @@ -1,6 +1,6 @@ diff --git a/templates/modify-class.tmpl b/templates/modify-class.tmpl index e36bb6b496..6d2655463f 100644 --- a/templates/modify-class.tmpl +++ b/templates/modify-class.tmpl @@ -4,6 +4,7 @@ +
{keytext}: -{[choices]{text}} +{[choices]{text}}
diff --git a/templates/option-boolean.tmpl b/templates/option-boolean.tmpl index 1b352bb1ff..e832ee1022 100644 --- a/templates/option-boolean.tmpl +++ b/templates/option-boolean.tmpl @@ -1,6 +1,6 @@ diff --git a/templates/pl/modify-class.tmpl b/templates/pl/modify-class.tmpl index c66cfda810..483cd06031 100644 --- a/templates/pl/modify-class.tmpl +++ b/templates/pl/modify-class.tmpl @@ -4,6 +4,7 @@ +
{keytext}: -{[choices]{text}} +{[choices]{text}}
diff --git a/templates/pl/option-boolean.tmpl b/templates/pl/option-boolean.tmpl index 1b352bb1ff..e832ee1022 100644 --- a/templates/pl/option-boolean.tmpl +++ b/templates/pl/option-boolean.tmpl @@ -1,6 +1,6 @@ diff --git a/templates/ru/modify-class.tmpl b/templates/ru/modify-class.tmpl index 7e0fbfbfa8..d596c9b3fd 100644 --- a/templates/ru/modify-class.tmpl +++ b/templates/ru/modify-class.tmpl @@ -4,6 +4,7 @@ +
{keytext}: -{[choices]{text}} +{[choices]{text}}
diff --git a/templates/ru/option-boolean.tmpl b/templates/ru/option-boolean.tmpl index 1b352bb1ff..e832ee1022 100644 --- a/templates/ru/option-boolean.tmpl +++ b/templates/ru/option-boolean.tmpl @@ -1,6 +1,6 @@ diff --git a/test/run-stp-tests.sh b/test/run-stp-tests.sh index c0199a61ad..1917565872 100755 --- a/test/run-stp-tests.sh +++ b/test/run-stp-tests.sh @@ -251,6 +251,7 @@ ln -s $root/notifier /tmp/cups-$user/bin ln -s $root/scheduler /tmp/cups-$user/bin/daemon ln -s $root/filter/bannertops /tmp/cups-$user/bin/filter ln -s $root/filter/commandtops /tmp/cups-$user/bin/filter +ln -s $root/filter/gziptoany /tmp/cups-$user/bin/filter ln -s $root/filter/hpgltops /tmp/cups-$user/bin/filter ln -s $root/filter/pstops /tmp/cups-$user/bin/filter ln -s $root/filter/rastertoepson /tmp/cups-$user/bin/filter diff --git a/tools/makesrcdist b/tools/makesrcdist index 9642409a5a..bda71393f8 100755 --- a/tools/makesrcdist +++ b/tools/makesrcdist @@ -32,7 +32,7 @@ else fileurl="ftp://ftp.easysw.com/pub/cups/$version/cups-$fileversion-source.tar." url="https://svn.easysw.com/public/cups/tags/release-$version" - svn copy https://svn.easysw.com/public/cups/trunk "$url" \ + svn copy https://svn.easysw.com/public/cups/branches/branch-1.4 "$url" \ -m "Tag $version" || exit 1 fi diff --git a/vc2005/config.h b/vc2005/config.h deleted file mode 100644 index 475ce61abb..0000000000 --- a/vc2005/config.h +++ /dev/null @@ -1,669 +0,0 @@ -/* - * "$Id$" - * - * Configuration file for the Common UNIX Printing System (CUPS). - * - * Copyright 2007-2009 by Apple Inc. - * Copyright 1997-2007 by Easy Software Products. - * - * These coded instructions, statements, and computer programs are the - * property of Apple Inc. and are protected by Federal copyright - * law. Distribution and use rights are outlined in the file "LICENSE.txt" - * which should have been included with this file. If this file is - * file is missing or damaged, see the license at "http://www.cups.org/". - */ - -#ifndef _CUPS_CONFIG_H_ -#define _CUPS_CONFIG_H_ - -/* - * Beginning with VC2005, Microsoft breaks ISO C and POSIX conformance - * by deprecating a number of functions in the name of security, even - * when many of the affected functions are otherwise completely secure. - * The _CRT_SECURE_NO_DEPRECATE definition ensures that we won't get - * warnings from their use... - * - * Then Microsoft decided that they should ignore this in VC2008 and use - * yet another define (_CRT_SECURE_NO_WARNINGS) instead. Bastards. - */ - -#define _CRT_SECURE_NO_DEPRECATE -#define _CRT_SECURE_NO_WARNINGS - - -/* - * Include necessary headers... - */ - -#include -#include -#include -#include -#include -#include - - -/* - * Microsoft also renames the POSIX functions to _name, and introduces - * a broken compatibility layer using the original names. As a result, - * random crashes can occur when, for example, strdup() allocates memory - * from a different heap than used by malloc() and free(). - * - * To avoid moronic problems like this, we #define the POSIX function - * names to the corresponding non-standard Microsoft names. - */ - -#define close _close -#define open _open -#define read _read -#define snprintf _snprintf -#define strdup _strdup -#define vsnprintf _vsnprintf -#define write _write - - -/* - * Compiler stuff... - */ - -#undef const -#undef __CHAR_UNSIGNED__ - - -/* - * Version of software... - */ - -#define CUPS_SVERSION "CUPS v1.4b3" -#define CUPS_MINIMAL "CUPS/1.4b3" - - -/* - * Default user and groups... - */ - -#define CUPS_DEFAULT_USER "lp" -#define CUPS_DEFAULT_GROUP "sys" -#define CUPS_DEFAULT_SYSTEM_GROUPS "admin" -#define CUPS_DEFAULT_PRINTOPERATOR_AUTH "@admin @lpadmin" - - -/* - * Default file permissions... - */ - -#define CUPS_DEFAULT_CONFIG_FILE_PERM 0644 -#define CUPS_DEFAULT_LOG_FILE_PERM 0644 - - -/* - * Default logging settings... - */ - -#define CUPS_DEFAULT_LOG_LEVEL "warn" -#define CUPS_DEFAULT_ACCESS_LOG_LEVEL "actions" - - -/* - * Default fatal error settings... - */ - -#define CUPS_DEFAULT_FATAL_ERRORS "config" - - -/* - * Default browsing settings... - */ - -#define CUPS_DEFAULT_BROWSING 1 -#define CUPS_DEFAULT_BROWSE_LOCAL_PROTOCOLS "CUPS dnssd" -#define CUPS_DEFAULT_BROWSE_REMOTE_PROTOCOLS "" -#define CUPS_DEFAULT_BROWSE_SHORT_NAMES 1 -#define CUPS_DEFAULT_DEFAULT_SHARED 1 -#define CUPS_DEFAULT_IMPLICIT_CLASSES 1 -#define CUPS_DEFAULT_USE_NETWORK_DEFAULT 0 - - -/* - * Default IPP port... - */ - -#define CUPS_DEFAULT_IPP_PORT 631 - - -/* - * Default printcap file... - */ - -#define CUPS_DEFAULT_PRINTCAP "" - - -/* - * Default Samba and LPD config files... - */ - -#define CUPS_DEFAULT_SMB_CONFIG_FILE "" -#define CUPS_DEFAULT_LPD_CONFIG_FILE "" - - -/* - * Default MaxCopies value... - */ - -#define CUPS_DEFAULT_MAX_COPIES 9999 - - -/* - * Do we have domain socket support? - */ - -#undef CUPS_DEFAULT_DOMAINSOCKET - - -/* - * Where are files stored? - * - * Note: These are defaults, which can be overridden by environment - * variables at run-time... - */ - -#define CUPS_BINDIR "C:/CUPS/bin" -#define CUPS_CACHEDIR "C:/CUPS/cache" -#define CUPS_DATADIR "C:/CUPS/share" -#define CUPS_DOCROOT "C:/CUPS/share/doc" -#define CUPS_FONTPATH "C:/CUPS/share/fonts" -#define CUPS_LOCALEDIR "C:/CUPS/locale" -#define CUPS_LOGDIR "C:/CUPS/logs" -#define CUPS_REQUESTS "C:/CUPS/spool" -#define CUPS_SBINDIR "C:/CUPS/sbin" -#define CUPS_SERVERBIN "C:/CUPS/lib" -#define CUPS_SERVERROOT "C:/CUPS/etc" -#define CUPS_STATEDIR "C:/CUPS/run" - - -/* - * Do we have various image libraries? - */ - -/* #undef HAVE_LIBPNG */ -/* #undef HAVE_LIBZ */ -/* #undef HAVE_LIBJPEG */ -/* #undef HAVE_LIBTIFF */ - - -/* - * Do we have PAM stuff? - */ - -#ifndef HAVE_LIBPAM -#define HAVE_LIBPAM 0 -#endif /* !HAVE_LIBPAM */ - -/* #undef HAVE_PAM_PAM_APPL_H */ -/* #undef HAVE_PAM_SET_ITEM */ -/* #undef HAVE_PAM_SETCRED */ - - -/* - * Do we have ? - */ - -/* #undef HAVE_SHADOW_H */ - - -/* - * Do we have ? - */ - -/* #undef HAVE_CRYPT_H */ - - -/* - * Use , , and/or ? - */ - -#define HAVE_STRING_H 1 -/* #undef HAVE_STRINGS_H */ -/* #undef HAVE_BSTRING_H */ - - -/* - * Do we have the long long type? - */ - -/* #undef HAVE_LONG_LONG */ - -#ifdef HAVE_LONG_LONG -# define CUPS_LLFMT "%lld" -# define CUPS_LLCAST (long long) -#else -# define CUPS_LLFMT "%ld" -# define CUPS_LLCAST (long) -#endif /* HAVE_LONG_LONG */ - - -/* - * Do we have the strtoll() function? - */ - -/* #undef HAVE_STRTOLL */ - -#ifndef HAVE_STRTOLL -# define strtoll(nptr,endptr,base) strtol((nptr), (endptr), (base)) -#endif /* !HAVE_STRTOLL */ - - -/* - * Do we have the strXXX() functions? - */ - -#define HAVE_STRDUP -#define HAVE_STRCASECMP -#define HAVE_STRNCASECMP -/* #undef HAVE_STRLCAT */ -/* #undef HAVE_STRLCPY */ - - -/* - * Do we have the geteuid() function? - */ - -/* #undef HAVE_GETEUID */ - - -/* - * Do we have the vsyslog() function? - */ - -/* #undef HAVE_VSYSLOG */ - - -/* - * Do we have the (v)snprintf() functions? - */ - -#define HAVE_SNPRINTF 1 -#define HAVE_VSNPRINTF 1 - - -/* - * What signal functions to use? - */ - -/* #undef HAVE_SIGSET */ -/* #undef HAVE_SIGACTION */ - - -/* - * What wait functions to use? - */ - -/* #undef HAVE_WAITPID */ -/* #undef HAVE_WAIT3 */ - - -/* - * Do we have the mallinfo function and malloc.h? - */ - -/* #undef HAVE_MALLINFO */ -/* #undef HAVE_MALLOC_H */ - - -/* - * Do we have the POSIX ACL functions? - */ - -/* #undef HAVE_ACL_INIT */ - - -/* - * Do we have the langinfo.h header file? - */ - -/* #undef HAVE_LANGINFO_H */ - - -/* - * Which encryption libraries do we have? - */ - -/* #undef HAVE_CDSASSL */ -/* #undef HAVE_GNUTLS */ -/* #undef HAVE_LIBSSL */ -/* #undef HAVE_SSL */ - - -/* - * What Security framework headers do we have? - */ - -/* #undef HAVE_AUTHORIZATION_H */ -/* #undef HAVE_SECPOLICY_H */ -/* #undef HAVE_SECPOLICYPRIV_H */ -/* #undef HAVE_SECBASEPRIV_H */ -/* #undef HAVE_SECIDENTITYSEARCHPRIV_H */ - - -/* - * Do we have the SecIdentitySearchCreateWithPolicy function? - */ - -/* #undef HAVE_SECIDENTITYSEARCHCREATEWITHPOLICY */ - - -/* - * Do we have the SLP library? - */ - -/* #undef HAVE_LIBSLP */ - - -/* - * Do we have an LDAP library? - */ - -/* #undef HAVE_LDAP */ -/* #undef HAVE_OPENLDAP */ -/* #undef HAVE_MOZILLA_LDAP */ -/* #undef HAVE_LDAP_SSL_H */ -/* #undef HAVE_LDAP_SSL */ -/* #undef HAVE_LDAP_REBIND_PROC */ - - -/* - * Do we have libpaper? - */ - -/* #undef HAVE_LIBPAPER */ - - -/* - * Do we have DNS Service Discovery (aka Bonjour)? - */ - -#define HAVE_DNSSD 1 - - -/* - * Do we have ? - */ - -/* #undef HAVE_SYS_IOCTL_H */ - - -/* - * Does the "tm" structure contain the "tm_gmtoff" member? - */ - -/* #undef HAVE_TM_GMTOFF */ - - -/* - * Do we have rresvport_af()? - */ - -/* #undef HAVE_RRESVPORT_AF */ - - -/* - * Do we have getaddrinfo()? - */ - -#define HAVE_GETADDRINFO 1 - - -/* - * Do we have getnameinfo()? - */ - -#define HAVE_GETNAMEINFO 1 - - -/* - * Do we have getifaddrs()? - */ - -/* #undef HAVE_GETIFADDRS */ - - -/* - * Do we have hstrerror()? - */ - -/* #undef HAVE_HSTRERROR */ - - -/* - * Do we have res_init()? - */ - -/* #undef HAVE_RES_INIT */ - - -/* - * Do we have - */ - -/* #undef HAVE_RESOLV_H */ - - -/* - * Do we have the header file? - */ - -/* #undef HAVE_SYS_SOCKIO_H */ - - -/* - * Does the sockaddr structure contain an sa_len parameter? - */ - -/* #undef HAVE_STRUCT_SOCKADDR_SA_LEN */ - - -/* - * Do we have the AIX usersec.h header file? - */ - -/* #undef HAVE_USERSEC_H */ - - -/* - * Do we have pthread support? - */ - -/* #undef HAVE_PTHREAD_H */ - - -/* - * Do we have launchd support? - */ - -/* #undef HAVE_LAUNCH_H */ -/* #undef HAVE_LAUNCHD */ -#define CUPS_DEFAULT_LAUNCHD_CONF "" - - -/* - * Various scripting languages... - */ - -/* #undef HAVE_JAVA */ -#define CUPS_JAVA "" -/* #undef HAVE_PERL */ -#define CUPS_PERL "" -/* #undef HAVE_PHP */ -#define CUPS_PHP "" -/* #undef HAVE_PYTHON */ -#define CUPS_PYTHON "" - - -/* - * Location of the poppler/Xpdf pdftops program... - */ - -/* #undef HAVE_PDFTOPS */ -#define CUPS_PDFTOPS "" - - -/* - * Location of the Ghostscript gs program... - */ - -/* #undef HAVE_GHOSTSCRIPT */ -#define CUPS_GHOSTSCRIPT "" - - -/* - * Do we have Darwin's CoreFoundation and SystemConfiguration frameworks? - */ - -/* #undef HAVE_COREFOUNDATION */ -/* #undef HAVE_SYSTEMCONFIGURATION */ - - -/* - * Do we have CoreFoundation public and private headers? - */ - -/* #undef HAVE_COREFOUNDATION_H */ -/* #undef HAVE_CFPRIV_H */ -/* #undef HAVE_CFBUNDLEPRIV_H */ - - -/* - * Do we have MacOSX 10.4's mbr_XXX functions()? - */ - -/* #undef HAVE_MEMBERSHIP_H */ -/* #undef HAVE_MEMBERSHIPPRIV_H */ -/* #undef HAVE_MBR_UID_TO_UUID */ - - -/* - * Do we have Darwin's notify_post() header and function? - */ - -/* #undef HAVE_NOTIFY_H */ -/* #undef HAVE_NOTIFY_POST */ - - -/* - * Do we have DBUS? - */ - -/* #undef HAVE_DBUS */ -/* #undef HAVE_DBUS_MESSAGE_ITER_INIT_APPEND */ - - -/* - * Do we have the AppleTalk/at_proto.h header? - */ - -/* #undef HAVE_APPLETALK_AT_PROTO_H */ - - -/* - * Do we have the GSSAPI support library (for Kerberos support)? - */ - -/* #undef HAVE_GSSAPI */ -/* #undef HAVE_GSSAPI_H */ -/* #undef HAVE_GSSAPI_GSSAPI_H */ -/* #undef HAVE_GSSAPI_GSSAPI_GENERIC_H */ -/* #undef HAVE_GSSAPI_GSSAPI_KRB5_H */ -/* #undef HAVE_GSSKRB5_REGISTER_ACCEPTOR_IDENTITY */ -/* #undef HAVE_GSS_C_NT_HOSTBASED_SERVICE */ -/* #undef HAVE_KRB5_CC_NEW_UNIQUE */ -/* #undef HAVE_KRB5_IPC_CLIENT_SET_TARGET_UID */ -/* #undef HAVE_KRB5_H */ -/* #undef HAVE_HEIMDAL */ - - -/* - * Default GSS service name... - */ - -#define CUPS_DEFAULT_GSSSERVICENAME "ipp" - - -/* - * Select/poll interfaces... - */ - -/* #undef HAVE_POLL */ -/* #undef HAVE_EPOLL */ -/* #undef HAVE_KQUEUE */ - - -/* - * Do we have the header? - */ - -/* #undef HAVE_DLFCN_H */ - - -/* - * Do we have ? - */ - -/* #undef HAVE_SYS_PARAM_H */ - - -/* - * Do we have ? - */ - -/* #undef HAVE_SYS_UCRED_H */ - - -/* - * Do we have removefile()? - */ - -/* #undef HAVE_REMOVEFILE */ - - -/* - * Do we have ? - */ - -/* #undef HAVE_SANDBOX_H */ - - -/* - * Which random number generator function to use... - */ - -/* #undef HAVE_RANDOM */ -/* #undef HAVE_MRAND48 */ -/* #undef HAVE_LRAND48 */ - - -/* - * Do we have vproc_transaction_begin/end? - */ - -/* #undef HAVE_VPROC_TRANSACTION_BEGIN */ - - -/* - * Do we have libusb? - */ - -/* #undef HAVE_USB_H */ - - -/* - * Do we have libwrap and tcpd.h? - */ - -/* #undef HAVE_TCPD_H */ - - -#endif /* !_CUPS_CONFIG_H_ */ - -/* - * End of "$Id$". - */ diff --git a/vc2005/cups.sln b/vc2005/cups.sln index a8a8cab3dc..00353516b6 100644 --- a/vc2005/cups.sln +++ b/vc2005/cups.sln @@ -12,22 +12,49 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "testhttp", "testhttp.vcproj {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3} = {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3} EndProjectSection EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cupstestppd", "cupstestppd.vcproj", "{6BE0CDD3-4ED7-409C-A80F-19DF73664B1F}" + ProjectSection(ProjectDependencies) = postProject + {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3} = {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3} + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 Release|Win32 = Release|Win32 + Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Debug|Win32.ActiveCfg = Debug|Win32 {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Debug|Win32.Build.0 = Debug|Win32 - {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Release|Win32.ActiveCfg = Release|Win32 - {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Release|Win32.Build.0 = Release|Win32 + {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Debug|x64.ActiveCfg = Debug|x64 + {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Debug|x64.Build.0 = Debug|x64 + {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Release|Win32.ActiveCfg = Debug|Win32 + {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Release|Win32.Build.0 = Debug|Win32 + {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Release|x64.ActiveCfg = Debug|x64 + {CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}.Release|x64.Build.0 = Debug|x64 {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Debug|Win32.ActiveCfg = Debug|Win32 {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Debug|Win32.Build.0 = Debug|Win32 - {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Release|Win32.ActiveCfg = Release|Win32 - {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Release|Win32.Build.0 = Release|Win32 + {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Debug|x64.ActiveCfg = Debug|x64 + {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Debug|x64.Build.0 = Debug|x64 + {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Release|Win32.ActiveCfg = Debug|Win32 + {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Release|Win32.Build.0 = Debug|Win32 + {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Release|x64.ActiveCfg = Debug|x64 + {CE75FC5F-E0CF-45DC-AD27-84666D3FBA30}.Release|x64.Build.0 = Debug|x64 {90B0058C-8393-411F-BD3B-E2C831D4E883}.Debug|Win32.ActiveCfg = Debug|Win32 - {90B0058C-8393-411F-BD3B-E2C831D4E883}.Release|Win32.ActiveCfg = Release|Win32 + {90B0058C-8393-411F-BD3B-E2C831D4E883}.Debug|Win32.Build.0 = Debug|Win32 + {90B0058C-8393-411F-BD3B-E2C831D4E883}.Debug|x64.ActiveCfg = Debug|x64 + {90B0058C-8393-411F-BD3B-E2C831D4E883}.Debug|x64.Build.0 = Debug|x64 + {90B0058C-8393-411F-BD3B-E2C831D4E883}.Release|Win32.ActiveCfg = Debug|Win32 + {90B0058C-8393-411F-BD3B-E2C831D4E883}.Release|Win32.Build.0 = Debug|Win32 + {90B0058C-8393-411F-BD3B-E2C831D4E883}.Release|x64.ActiveCfg = Debug|x64 + {90B0058C-8393-411F-BD3B-E2C831D4E883}.Release|x64.Build.0 = Debug|x64 + {6BE0CDD3-4ED7-409C-A80F-19DF73664B1F}.Debug|Win32.ActiveCfg = Debug|Win32 + {6BE0CDD3-4ED7-409C-A80F-19DF73664B1F}.Debug|Win32.Build.0 = Debug|Win32 + {6BE0CDD3-4ED7-409C-A80F-19DF73664B1F}.Debug|x64.ActiveCfg = Debug|Win32 + {6BE0CDD3-4ED7-409C-A80F-19DF73664B1F}.Release|Win32.ActiveCfg = Release|Win32 + {6BE0CDD3-4ED7-409C-A80F-19DF73664B1F}.Release|Win32.Build.0 = Release|Win32 + {6BE0CDD3-4ED7-409C-A80F-19DF73664B1F}.Release|x64.ActiveCfg = Release|Win32 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/vc2005/cupstestppd.vcproj b/vc2005/cupstestppd.vcproj new file mode 100644 index 0000000000..6fb4cfaff4 --- /dev/null +++ b/vc2005/cupstestppd.vcproj @@ -0,0 +1,215 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vc2005/libcups2.vcproj b/vc2005/libcups2.vcproj index 768fedf0eb..b080826d74 100644 --- a/vc2005/libcups2.vcproj +++ b/vc2005/libcups2.vcproj @@ -10,14 +10,17 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -193,7 +365,347 @@ > + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vcnet/libcups2.def b/vcnet/libcups2.def deleted file mode 100644 index 376fc2d4ba..0000000000 --- a/vcnet/libcups2.def +++ /dev/null @@ -1,284 +0,0 @@ -LIBRARY libcups2 -VERSION 2.7 -EXPORTS -_cupsAdminGetServerSettings -_cupsAdminSetServerSettings -_cupsCharmapFlush -_cupsCharmapFree -_cupsCharmapGet -_cupsEncodingName -_cupsGetPassword -_cupsGlobals -_cupsLangPrintf -_cupsLangPuts -_cupsLangString -_cupsMD5Append -_cupsMD5Finish -_cupsMD5Init -_cupsMessageFree -_cupsMessageLoad -_cupsMessageLookup -_cupsSetError -_cupsSetLocale -_cupsStrAlloc -_cupsStrFlush -_cupsStrFormatd -_cupsStrFree -_cupsStrScand -_cupsStrStatistics -_cups_strcpy -_cups_strlcat -_cups_strlcpy -_ippAddAttr -_ippFindOption -_ippFreeAttr -_ppdGetEncoding -cupsAddDest -cupsAddOption -cupsAdminCreateWindowsPPD -cupsAdminExportSamba -cupsArrayAdd -cupsArrayClear -cupsArrayCount -cupsArrayCurrent -cupsArrayDelete -cupsArrayDup -cupsArrayFind -cupsArrayFirst -cupsArrayIndex -cupsArrayInsert -cupsArrayLast -cupsArrayNew -cupsArrayNext -cupsArrayPrev -cupsArrayRemove -cupsArrayRestore -cupsArraySave -cupsArrayUserData -cupsCancelJob -cupsCharsetToUTF8 -cupsDirClose -cupsDirOpen -cupsDirRead -cupsDirRewind -cupsDoAuthentication -cupsDoFileRequest -cupsDoRequest -cupsEncodeOptions -cupsEncodeOptions2 -cupsEncryption -cupsFileClose -cupsFileCompression -cupsFileEOF -cupsFileFind -cupsFileFlush -cupsFileGetChar -cupsFileGetConf -cupsFileGetLine -cupsFileGets -cupsFileLock -cupsFileNumber -cupsFileOpen -cupsFileOpenFd -cupsFilePeekChar -cupsFilePrintf -cupsFilePutChar -cupsFilePuts -cupsFileRead -cupsFileRewind -cupsFileSeek -cupsFileStderr -cupsFileStdin -cupsFileStdout -cupsFileTell -cupsFileUnlock -cupsFileWrite -cupsFreeDests -cupsFreeJobs -cupsFreeOptions -cupsGetClasses -cupsGetDefault -cupsGetDefault2 -cupsGetDest -cupsGetDests -cupsGetDests2 -cupsGetFd -cupsGetFile -cupsGetJobs -cupsGetJobs2 -cupsGetOption -cupsGetPPD -cupsGetPPD2 -cupsGetPassword -cupsGetPrinters -cupsLangDefault -cupsLangEncoding -cupsLangFlush -cupsLangFree -cupsLangGet -cupsLastError -cupsLastErrorString -cupsMarkOptions -cupsNotifySubject -cupsNotifyText -cupsParseOptions -cupsPrintFile -cupsPrintFile2 -cupsPrintFiles -cupsPrintFiles2 -cupsPutFd -cupsPutFile -cupsRemoveOption -cupsServer -cupsSetDests -cupsSetDests2 -cupsSetEncryption -cupsSetPasswordCB -cupsSetServer -cupsSetUser -cupsTempFd -cupsTempFile -cupsTempFile2 -cupsUTF32ToUTF8 -cupsUTF8ToCharset -cupsUTF8ToUTF32 -cupsUser -httpAddrAny -httpAddrConnect -httpAddrEqual -httpAddrFreeList -httpAddrGetList -httpAddrLength -httpAddrLocalhost -httpAddrLookup -httpAddrString -httpAssembleURI -httpAssembleURIf -httpBlocking -httpCheck -httpClearCookie -httpClearFields -httpClose -httpConnect -httpConnectEncrypt -httpDecode64 -httpDecode64_2 -httpDelete -httpEncode64 -httpEncode64_2 -httpEncryption -httpError -httpFlush -httpFlushWrite -httpGet -httpGetBlocking -httpGetCookie -httpGetDateString -httpGetDateString2 -httpGetDateTime -httpGetFd -httpGetField -httpGetHostByName -httpGetHostname -httpGetLength -httpGetLength2 -httpGetStatus -httpGetSubField -httpGetSubField2 -httpGets -httpHead -httpInitialize -httpMD5 -httpMD5Final -httpMD5String -httpOptions -httpPost -httpPrintf -httpPut -httpRead -httpRead2 -httpReconnect -httpSeparate -httpSeparate2 -httpSeparateURI -httpSetCookie -httpSetExpect -httpSetField -httpSetLength -httpStatus -httpTrace -httpUpdate -httpWait -httpWrite -httpWrite2 -ippAddBoolean -ippAddBooleans -ippAddCollection -ippAddCollections -ippAddDate -ippAddInteger -ippAddIntegers -ippAddOctetString -ippAddRange -ippAddRanges -ippAddResolution -ippAddResolutions -ippAddSeparator -ippAddString -ippAddStrings -ippDateToTime -ippDelete -ippDeleteAttribute -ippErrorString -ippErrorValue -ippFindAttribute -ippFindNextAttribute -ippLength -ippNew -ippNewRequest -ippOpString -ippOpValue -ippPort -ippRead -ippReadFile -ippReadIO -ippSetPort -ippTimeToDate -ippWrite -ippWriteFile -ippWriteIO -ppdClose -ppdCollect -ppdCollect2 -ppdConflicts -ppdEmit -ppdEmitAfterOrder -ppdEmitFd -ppdEmitJCL -ppdEmitJCLEnd -ppdEmitString -ppdErrorString -ppdFindAttr -ppdFindChoice -ppdFindCustomOption -ppdFindCustomParam -ppdFindMarkedChoice -ppdFindNextAttr -ppdFindOption -ppdFirstCustomParam -ppdFirstOption -ppdIsMarked -ppdLastError -ppdLocalize -ppdMarkDefaults -ppdMarkOption -ppdNextCustomParam -ppdNextOption -ppdOpen -ppdOpen2 -ppdOpenFd -ppdOpenFile -ppdPageLength -ppdPageSize -ppdPageWidth -ppdSetConformance diff --git a/vcnet/libcups2.vcproj b/vcnet/libcups2.vcproj index 6a4a824e4b..983e7da2a1 100644 --- a/vcnet/libcups2.vcproj +++ b/vcnet/libcups2.vcproj @@ -4,7 +4,6 @@ Version="9.00" Name="libcups2" ProjectGUID="{CB4AA6F2-3E84-45BE-B505-95CD375E8BE3}" - RootNamespace="libcups2" Keyword="Win32Proj" TargetFrameworkVersion="131072" > @@ -12,14 +11,17 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -193,7 +364,347 @@ > + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -42,13 +42,13 @@ Name="VCCLCompilerTool" Optimization="0" AdditionalIncludeDirectories="..\vcnet;.." - PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE" + PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;_CRT_SECURE_NO_DEPRECATE" MinimalRebuild="true" BasicRuntimeChecks="3" RuntimeLibrary="1" UsePrecompiledHeader="0" WarningLevel="3" - Detect64BitPortabilityProblems="true" + Detect64BitPortabilityProblems="false" DebugInformationFormat="4" />
{keytext}: -{[choices]{text}} +{[choices]{text}}