diff options
author | Slávek Banko <slavek.banko@axis.cz> | 2014-12-25 19:10:23 +0100 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2014-12-25 19:10:23 +0100 |
commit | 592bebb509786ccec893b305d3ae6a0c76ed3bdb (patch) | |
tree | 722ddc4b49f973de46216b8d0cfe5bb0dc1f35f5 /tdeprint/cups/ipprequest.cpp | |
parent | 840c1c22173103e70547f2784f988473359fa4d6 (diff) | |
download | tdelibs-592bebb509786ccec893b305d3ae6a0c76ed3bdb.tar.gz tdelibs-592bebb509786ccec893b305d3ae6a0c76ed3bdb.zip |
Fix FTBFS because CUPS 2.x
This resolves Bug 2270
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
Diffstat (limited to 'tdeprint/cups/ipprequest.cpp')
-rw-r--r-- | tdeprint/cups/ipprequest.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tdeprint/cups/ipprequest.cpp b/tdeprint/cups/ipprequest.cpp index b4e39913d..8a363152b 100644 --- a/tdeprint/cups/ipprequest.cpp +++ b/tdeprint/cups/ipprequest.cpp @@ -407,7 +407,7 @@ bool IppRequest::doFileRequest(const TQString& res, const TQString& filename) } #ifdef HAVE_CUPS_NO_PWD_CACHE -#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR <= 2 +#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2) strncpy( HTTP->authstring, cups_authstring.data(), HTTP_MAX_VALUE ); #else httpSetAuthString( HTTP, NULL, cups_authstring.data() ); @@ -421,7 +421,7 @@ bool IppRequest::doFileRequest(const TQString& res, const TQString& filename) request_ = cupsDoFileRequest(HTTP, request_, (res.isEmpty() ? "/" : res.latin1()), (filename.isEmpty() ? NULL : filename.latin1())); #ifdef HAVE_CUPS_NO_PWD_CACHE -#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR <= 2 +#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2) cups_authstring = HTTP->authstring; #else cups_authstring = httpGetAuthString( HTTP ); @@ -757,7 +757,7 @@ void IppRequest::setMap(const TQMap<TQString,TQString>& opts) cupsFreeOptions(n, options); // find an remove that annoying "document-format" attribute -#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2 +#if CUPS_VERSION_MAJOR > 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2) ipp_attribute_t *attr = ippFindAttribute(request_, "document-format", IPP_TAG_NAME); ippDeleteAttribute(request_, attr); #else |