summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVincent Untz <vuntz@novell.com>2010-02-16 18:23:56 +0100
committerVincent Untz <vuntz@novell.com>2010-02-16 18:23:56 +0100
commit5ae0b9036f1fef5fdf64439b9e8a8da44082ba13 (patch)
treea75d3815daaf29a5308b9f82b2c1ea09043a926a
parent8d646a9c09ce6c38f17a6fd421d890b365a56d23 (diff)
Also respect the timeout when getting devices with pre cups 1.4 code
-rw-r--r--src/cups.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/cups.c b/src/cups.c
index 2d1a360..15d92b7 100644
--- a/src/cups.c
+++ b/src/cups.c
@@ -1911,6 +1911,11 @@ cph_cups_devices_get (CphCups *cups,
const char *device_uri;
request = ippNewRequest (CUPS_GET_DEVICES);
+
+ if (timeout > 0)
+ ippAddInteger (request, IPP_TAG_OPERATION, IPP_TAG_INTEGER,
+ "timeout", timeout);
+
resource_char = _cph_cups_get_resource (CPH_RESOURCE_ROOT);
reply = cupsDoRequest (cups->priv->connection,
request, resource_char);