diff options
author | Michael Terry <michael.terry@canonical.com> | 2011-08-18 12:26:29 -0400 |
---|---|---|
committer | Michael Terry <michael.terry@canonical.com> | 2011-08-18 12:26:29 -0400 |
commit | b91c0d380a7774f601e7016af99d35c415e84675 (patch) | |
tree | fefc450bf6dd41e51003fe7038698040520c56ea | |
parent | 2584b255009f3f36358425c74549175a11a57008 (diff) | |
download | lightdm-git-b91c0d380a7774f601e7016af99d35c415e84675.tar.gz |
treat zero-returns on stream writes as success
-rw-r--r-- | src/xauthority.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/xauthority.c b/src/xauthority.c index ba770c62..837ee448 100644 --- a/src/xauthority.c +++ b/src/xauthority.c @@ -206,13 +206,13 @@ write_uint16 (GOutputStream *stream, guint16 value, GError **error) data[0] = value >> 8; data[1] = value & 0xFF; - return g_output_stream_write (stream, data, 2, NULL, error); + return g_output_stream_write (stream, data, 2, NULL, error) >= 0; } static gboolean write_data (GOutputStream *stream, const guint8 *data, gsize data_length, GError **error) { - return g_output_stream_write (stream, data, data_length, NULL, error); + return g_output_stream_write (stream, data, data_length, NULL, error) >= 0; } static gboolean |