summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Vogelgesang <matthias.vogelgesang@kit.edu>2016-04-13 14:32:18 +0200
committerMatthias Vogelgesang <matthias.vogelgesang@kit.edu>2016-04-13 14:32:18 +0200
commit63b4d9a96ba2e8266262c7f6f36b5f44af894964 (patch)
treecb7aaeccb7b65ad76a46923ed1da1236ebd29c9a
parent11df31665f219ee9c64911f376d3f030982fa9f8 (diff)
downloaduca-net-63b4d9a96ba2e8266262c7f6f36b5f44af894964.tar.gz
uca-net-63b4d9a96ba2e8266262c7f6f36b5f44af894964.tar.bz2
uca-net-63b4d9a96ba2e8266262c7f6f36b5f44af894964.tar.xz
uca-net-63b4d9a96ba2e8266262c7f6f36b5f44af894964.zip
Match different errors for GLib <= 2.36
-rw-r--r--ucad.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ucad.c b/ucad.c
index 02e2f95..4d46bca 100644
--- a/ucad.c
+++ b/ucad.c
@@ -366,7 +366,11 @@ serve_connection (GSocketConnection *connection, UcaCamera *camera)
g_input_stream_read (input, buffer, 4096, NULL, &error);
message = (UcaNetMessageDefault *) buffer;
+#if (GLIB_CHECK_VERSION (2, 36, 0))
if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_BROKEN_PIPE)) {
+#else
+ if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_FAILED)) {
+#endif
g_error_free (error);
error = NULL;
active = FALSE;