summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Vogelgesang <matthias.vogelgesang@gmail.com>2012-05-31 17:19:30 +0200
committerMatthias Vogelgesang <matthias.vogelgesang@gmail.com>2012-05-31 17:19:30 +0200
commitb1e3aa27d505551a6e3656ecb828ac05617badaa (patch)
tree3c19878d3efbdaef59353858b62259c3e23c1f73
parent55bc72a569e37ae029bf87a08ea479e960d2088c (diff)
downloadlibuca-b1e3aa27d505551a6e3656ecb828ac05617badaa.tar.gz
libuca-b1e3aa27d505551a6e3656ecb828ac05617badaa.tar.bz2
libuca-b1e3aa27d505551a6e3656ecb828ac05617badaa.tar.xz
libuca-b1e3aa27d505551a6e3656ecb828ac05617badaa.zip
Warn if cooling point cannot be set/read
-rw-r--r--src/cameras/uca-pco-camera.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/cameras/uca-pco-camera.c b/src/cameras/uca-pco-camera.c
index dfc29e4..ad5cb77 100644
--- a/src/cameras/uca-pco-camera.c
+++ b/src/cameras/uca-pco-camera.c
@@ -284,6 +284,8 @@ static guint override_temperature_range(UcaPcoCameraPrivate *priv)
spec->maximum = max_temp;
spec->default_value = default_temp;
}
+ else
+ g_warning("Unable to retrieve cooling range");
return err;
}
@@ -966,7 +968,8 @@ static void uca_pco_camera_get_property(GObject *object, guint property_id, GVal
case PROP_COOLING_POINT:
{
int16_t temperature;
- pco_get_cooling_temperature(priv->pco, &temperature);
+ if (pco_get_cooling_temperature(priv->pco, &temperature) != PCO_NOERROR)
+ g_warning("Cannot read cooling temperature\n");
g_value_set_int(value, temperature);
}
break;