summaryrefslogtreecommitdiff
path: root/src/cairo-device.c
diff options
context:
space:
mode:
authorAndrea Canciani <ranma42@gmail.com>2011-07-06 22:49:29 +0200
committerAndrea Canciani <ranma42@gmail.com>2011-07-08 11:26:45 +0200
commit02a331de13313085d671716031a3b61778014b87 (patch)
tree95d48f5cca4ef3e0c9effdc69d0b054fcd80946c /src/cairo-device.c
parent35d8d206355b281d09d50b61d6497cea39e09624 (diff)
downloadcairo-02a331de13313085d671716031a3b61778014b87.tar.gz
device: Define the CAIRO_DEVICE_TYPE_INVALID device type
Define a new device type to indicate that the device is not valid. The -1 value is along the same line as CAIRO_FORMAT_INVALID (and is likely to have the same issues).
Diffstat (limited to 'src/cairo-device.c')
-rw-r--r--src/cairo-device.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cairo-device.c b/src/cairo-device.c
index 3c200e0f0..b6dde631d 100644
--- a/src/cairo-device.c
+++ b/src/cairo-device.c
@@ -365,7 +365,7 @@ cairo_device_get_type (cairo_device_t *device)
if (device == NULL ||
CAIRO_REFERENCE_COUNT_IS_INVALID (&device->ref_count))
{
- return (cairo_device_type_t) -1;
+ return CAIRO_DEVICE_TYPE_INVALID;
}
return device->backend->type;