summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2015-02-16 13:14:39 +0100
committerMarc-André Lureau <marcandre.lureau@redhat.com>2015-02-18 13:50:34 +0100
commit71b4b286889e6143a28c07ab393d541dad1016ec (patch)
tree3e6ee674cf537c8d5b9c027a184320dc4a38a344
parented9066c19abe2558914f35d4f54d39bd5910285a (diff)
channel: remove unused ChannelClass::channel_disconnect()
This virtual method turns out to be unnecessary anymore, and was never override. channel_reset() is enough.
-rw-r--r--gtk/spice-channel.c19
-rw-r--r--gtk/spice-channel.h2
2 files changed, 1 insertions, 20 deletions
diff --git a/gtk/spice-channel.c b/gtk/spice-channel.c
index 0d5e5e7..95eb615 100644
--- a/gtk/spice-channel.c
+++ b/gtk/spice-channel.c
@@ -51,7 +51,6 @@
static void spice_channel_handle_msg(SpiceChannel *channel, SpiceMsgIn *msg);
static void spice_channel_write_msg(SpiceChannel *channel, SpiceMsgOut *out);
static void spice_channel_send_link(SpiceChannel *channel);
-static void channel_disconnect(SpiceChannel *channel);
static void channel_reset(SpiceChannel *channel, gboolean migrating);
static void spice_channel_reset_capabilities(SpiceChannel *channel);
static void spice_channel_send_migration_handshake(SpiceChannel *channel);
@@ -270,7 +269,6 @@ static void spice_channel_class_init(SpiceChannelClass *klass)
klass->iterate_write = spice_channel_iterate_write;
klass->iterate_read = spice_channel_iterate_read;
- klass->channel_disconnect = channel_disconnect;
klass->channel_reset = channel_reset;
gobject_class->constructed = spice_channel_constructed;
@@ -2643,23 +2641,6 @@ void spice_channel_reset(SpiceChannel *channel, gboolean migrating)
SPICE_CHANNEL_GET_CLASS(channel)->channel_reset(channel, migrating);
}
-/* system or coroutine context */
-static void channel_disconnect(SpiceChannel *channel)
-{
- SpiceChannelPrivate *c = channel->priv;
-
- g_return_if_fail(c != NULL);
-
- if (c->state == SPICE_CHANNEL_STATE_UNCONNECTED)
- return;
-
- c->has_error = TRUE; /* break the loop */
-
- spice_channel_reset(channel, FALSE);
-
- g_return_if_fail(SPICE_IS_CHANNEL(channel));
-}
-
/**
* spice_channel_disconnect:
* @channel:
diff --git a/gtk/spice-channel.h b/gtk/spice-channel.h
index 8d07383..7f132f6 100644
--- a/gtk/spice-channel.h
+++ b/gtk/spice-channel.h
@@ -86,7 +86,7 @@ struct _SpiceChannelClass
/*< private >*/
/* virtual method, any context */
- void (*channel_disconnect)(SpiceChannel *channel);
+ gpointer deprecated;
void (*channel_reset)(SpiceChannel *channel, gboolean migrating);
void (*channel_reset_capabilities)(SpiceChannel *channel);