summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrediano Ziglio <freddy77@gmail.com>2020-10-02 13:09:41 +0100
committerFrediano Ziglio <freddy77@gmail.com>2020-10-05 10:05:24 +0100
commitee7f5908cff0cae246a220a29ac721e48cddcd14 (patch)
tree38fb5735d91fc7eaddd8fadacd405f5addc6b89b
parent94087502a056ed6b386b798012e09f0029a14843 (diff)
channel-main: Add comment on handling GLib I/O error statuses
Document a behaviour in the code asked a couple of times. Signed-off-by: Frediano Ziglio <freddy77@gmail.com> Acked-by: Marc-André Lureau <marcandre.lureau@redhat.com>
-rw-r--r--src/channel-main.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/channel-main.c b/src/channel-main.c
index 5fefded..060b70c 100644
--- a/src/channel-main.c
+++ b/src/channel-main.c
@@ -1947,6 +1947,9 @@ static void main_agent_handle_xfer_status(SpiceMainChannel *channel,
error = g_error_new_literal(G_IO_ERROR, err->error_code,
_("Invalid filename of transferred file"));
break;
+ /* Note that if the switch doesn't handle some code, "error" is
+ * left NULL so it will be treated as default error and
+ * assigned a generic message. This is a wanted behaviour. */
}
}
if (error == NULL) {